Widget Configuration
Paramater | Description | Data format |
---|---|---|
asset_type | currency code | string |
to_address | wallet address to send assets to | string |
amount_type | "fiat" or "crypto" | string |
amount | amount of assets | number |
network | supported network | string |
webhook_url | postback url | string |
additional_fields[0] | your custom data | string |
additional_fields[key] | your custom data | string |
asset_type
- requires currency code for supported assets, using this parameter locks asset type to enable only buying of this asset and prevents user from changing to different cryptocurrency, should be in lowercaseto_address
- setting this parameter locks user from changing destination wallet address. Ifto_address
is defined then eitherasset_type
or network parameters also need to be definedamount_type
- possible options for this parameters are "fiat
" or "crypto
". Default fiat is EUR. This field is required ifamount
parameter is being sent, and it defines whether the definedamount
is crypto or fiatamount
- define how much user will be buying, setting this parameter locks user from changing amount valuewebhook_url
- destination for postback dataadditional_fields
- can use number or string as key, there is no limit for number of additional fields usednetwork
- defines supported network and filters available coins shown in UI according to it
POST https://api.kriptomat.io/widget/init
{
"token": "6a7d2e91d4cff64939450c74001da4f24fbabd2abae8b2fc1c79a561da9de14a",
"asset_type": "eth",
"to_address": "0x7873ce9E57c6aEEA16aD6AE759CE955736f14e96",
"amount": 35,
"amount_type": "fiat",
}
{
"status": "true",
"data":
{
"url": "https://widget.kriptomat.io/?to_address=1DJ4N7mdUazDvrDe3H5eeRJtoXuAUSbTWy&amount=35&asset_type=eth&uuid=c472856c-d248-4e53-ae49-1d2f088cb732",
}
}
Last modified 5mo ago