Token
Post Token
Create Token
1 min
name create token method post url https secure paydocker com version token partnerid randomkey description tab examples examples languages id yn8gve8kwodb4fruswwkt language json code n share secret string n token event create n source id string n destination id string n destination currency string n founding balance string n load amount string n available date string n expiry date string n check in string n check out string n room count number n blockchain processing boolean n customer name string n booking reference string n email token boolean n email settings n n email to string n email encrypted boolean n n n customlabel id avjjlfjqpw0dm 5vcd7sy language curl code curl location g request post https secure paydocker com version token partnerid randomkey n header accept application json n header content type application json n data raw share secret string token event string source id string destination id string destination currency string founding balance string load amount string available date string expiry date string token category string blockchain processing boolean token name string token reference string email token boolean email settings object customlabel id wfbdwakalksfwa5tzbc1w language nodejs code var request require request ; nvar options n method post n url https secure paydocker com version token partnerid randomkey n headers n accept application json n content type application json n n body json stringify n share secret string n token event string n source id string n destination id string n destination currency string n founding balance string n load amount string n available date string n expiry date string n token category string n blockchain processing boolean n token name string n token reference string n email token boolean n email settings object n n n ; nrequest options function error response n if error throw new error error ; n console log response body ; n ; n customlabel id wmfgchfv1ahj4zgtbx8l2 language javascript code var myheaders new headers ; nmyheaders append accept application json ; nmyheaders append content type application json ; n nvar raw json stringify n share secret string n token event string n source id string n destination id string n destination currency string n founding balance string n load amount string n available date string n expiry date string n token category string n blockchain processing boolean n token name string n token reference string n email token boolean n email settings object n ; n nvar requestoptions n method post n headers myheaders n body raw n redirect follow n ; n nfetch https secure paydocker com version token partnerid randomkey requestoptions n then response response text n then result console log result n catch error console log error error ; customlabel id vjfh90 kkrbcf1ylggonl language python code import requests nimport json n nurl https secure paydocker com version token partnerid randomkey n npayload json dumps n share secret string n token event string n source id string n destination id string n destination currency string n founding balance string n load amount string n available date string n expiry date string n token category string n blockchain processing boolean n token name string n token reference string n email token boolean n email settings object n nheaders n accept application json n content type application json n n nresponse requests request post url headers headers data payload n nprint response text n customlabel id fzz6zgvnw51fs0fb4ulkq language ruby code require uri nrequire json nrequire net http n nurl uri https secure paydocker com version token partnerid randomkey n nhttps net http new url host url port nhttps use ssl true n nrequest net http post new url nrequest accept application json nrequest content type application json nrequest body json dump n share secret string n token event string n source id string n destination id string n destination currency string n founding balance string n load amount string n available date string n expiry date string n token category string n blockchain processing boolean n token name string n token reference string n email token boolean n email settings object n n nresponse https request request nputs response read body n customlabel selectedlanguageid avjjlfjqpw0dm 5vcd7sy results languages id eucjsgygen2hixnejt vo language 200 code n fee amount 1 05 n message success n success true n token id 528991181481 n token multimedia https rb gy gtpb9h n customlabel id gc6sfskvl0q awpzoq1hg language 403 code n success false n errors n code 403 n message ip not allowed n n customlabel id vdgndcw0rix6ewz ksdk language 405 customlabel code n success false n errors n code 405 n message method not allowed n n id m7fgcepssycuenth ksof language 406 code n success false n errors n code 406 n message enpoint bad format n n customlabel id l5ewi8wcaomp907fgcffe language 408 code n success false n errors n code 408 n message endpoint suspended n n customlabel id h5o8qbnvq6qwneuxrtmua language 409 code n success false n errors n code 409 n message event not allowed n n customlabel id hskxymapres2vjbadxzam language 410 code n success false n errors n code 410 n message invalid secret key n n customlabel id wypc3mnc8mborfcacowbz language 411 code n success false n errors n code 411 n message invalid balance id n n customlabel id kij6w7ypr2q0vd0qlzi 5 language 412 code n success false n errors n code 412 n message balance id is inactive n n customlabel id 8ykaeoj5489a32vm9zvzh language 415 code n success false n errors n code 415 n message invalid load amount n n customlabel id psmbk0haocxlr2hoojf3o language 417 code n success false n errors n code 417 n message invalid expiry date n n customlabel id lwn6xa3a4p42y 0inyynw language 418 code n success false n errors n code 417 n message invalid expiry date n n customlabel id 6qo7uzztc70hgpmvaumqi language 421 code n success false n errors n code 421 n message reference characters exceeded n n customlabel id kalccev0g0sh3zosoqkzk language 422 code n success false n errors n code 422 n message partnership status fail n n customlabel id qcdo5eiopeywibvybcdsr language 423 code n success false n errors n code 423 n message setup status fail n n customlabel id 2 6 a0tvsawevqm2v4ex language 424 code n success false n errors n code 424 n message account status fail n n customlabel id opuh8gzy jevhpjzqaxfd language 426 code n success false n errors n code 426 n message invalid email format n n customlabel id oxvxxc1a69b9njzjo 1ik language 100 code customlabel selectedlanguageid 2 6 a0tvsawevqm2v4ex request pathparameters queryparameters headerparameters bodydataparameters name share secret kind required type string description test mode secret keys and live mode secret keys are available in your paydocker account under integration menu n ndon t share your secret api keys in publicly accessible areas such as github client side code and so forth children name token event kind required type string description used to identify the action connected to the token and the allowed action for this request would be create children name source id kind required type string description your paydocker account id assigned upon account creation e g pdr1 it is case sensitive children name destination id kind required type string description property id e g id 001 generated in your platform it represents the token recipient children name destination currency kind required type string description currency id iso 4217 standard format associated within the token value nsupported currency and iso code are available in api reference standard codes currency code children name founding balance kind required type string description partner balance id uniquely associated with the currency of the token and where the token amount will be unloaded from e g pd74inr1385809982156467 children name load amount kind required type string description the sum added by the partner to the token which the recipient can then collect n nthe amount value supports up to twelve digits e g a value of 9 999 999 999 99 divided by decimal children name available date kind required type string description the date on which the token becomes active and ready for the recipient to collect n nthe format is dd mm yyyy e g 25 12 2023 n nselectable date range is 1 day before token creation day to up to 365 days in the future children name expiry date kind required type string description the date on which the token becomes invalid after which it cannot be used or collected by the recipient n nthe format is dd mm yyyy e g 25 12 2023 n nselectable date range is same or greater than available date essentially until the last day of the month one year after the chosen available date n ne g available date 18 oct 2023 expiry date 31 oct 2024 children name check in kind required type string description the format is dd mm yyyy e g 25 12 2023 n nselectable date range up to 2 years before token creation day to up to 2 years in the future n children name check out kind required type string description the format is yyyy mm dd e g 2023 12 21 n nselectable date range is same or greater than check in date up to 90 days in the future children name room count kind required type number description accepted value from 1 to 999 children name blockchain processing kind required type boolean description true or false only one option is applicable it is case sensitive children name customer name kind required type string description used to identify the customer name associated within the booking nmaximum 80 characters allowed children name booking reference kind required type string description used to identify the booking id nmaximum 200 characters allowed children name email token kind required type boolean description true or false only one option is applicable it is case sensitive children name email settings kind required type object description children name email to kind optional type string description the email address for token sharing token details can be shared with a range of one to ten email addresses by using commas to separate them name email encrypted kind optional type boolean description true or false only one option is applicable it is case sensitive n nif true token will be encrypted when shared with the email addresses formdataparameters currentnewparameter label body parameter value bodydataparameters