Once you've included this script on your website, you'll need to create the code that will bootstrap this application and render the iframe.
Your code must assign a function to window.primeTrustReady that accepts 1 argument, an instance of the Prime Trust Embedding API. This function will be run once embedding is possible. You can set this function up before or after loading the the script tag.
This is an example of initializing our account creation application:
+target - HTMLElement or string of an element's id: target to create iframe inside. This should be a block-level element (div, section, etc) with no children.
theme - object: an object of hexadecimal colors to customize the appearance of the embedded applications. You only need to specify the colors you wish to override. The most common values to change are primary (controls the accent color that defaults to blue) and success (controls the color of the Next and Previous buttons).
resourceTokenHash - string: used to make authenticated API calls cand created via the /v2/resource-tokens or /v2/credit-card-resources API
width - number: overrides the default width of the iframe, currently defaults to 632 pixels
height - number: overrides the default height of the iframe, currently defaults to 850 pixels
events: - object: an object of callbacks. All applications have a loaded event, but individual applications will have other events available as well.
Example of a loaded event hook:
console.log('The Prime Trust application is ready for user input');