Booking
Cancel Booking
1 min
name cancel booking method delete url https api paydocker com version booking partnerid randomkey description this api allow to cancel a previous created booking in your paydocker account tab examples examples languages id mq0bwfsdgkd5w06ldf55z language json code n share secret ixmaguhdavk3zzcujbczaasdvdqcky4p3gnzl4wstmvxal1avp2voa2qwvnmwfonvt0x0n6wbaudnmatbekhmduj8vvascr5fpkmf9rdjp5sy63evytcpnhns2crcx9sbmudlzfjwnfsku2bisq8mw n booking event cancel n source id pdr7 n booking id api bk58 n customlabel id gbhm77grjts6airhitjq5 language nodejs code var request require request ; nvar options n method delete n url https api paydocker com version booking partnerid randomkey cancel n headers n accept application json n content type application json n n body json stringify n share secret ixmaguhdavk3zzcujbczaasdvdqcky4p3gnzl4wstmvxal1avp2voa2qwvnmwfonvt0x0n6wbaudnmatbekhmduj8vvascr5fpkmf9rdjp5sy63evytcpnhns2crcx9sbmudlzfjwnfsku2bisq8mw n booking event cancel n source id pdr7 n booking id api bk58 n n n ; nrequest options function error response n if error throw new error error ; n console log response body ; n ; n customlabel id v3gczdv2c90poyfas6mec 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 ixmaguhdavk3zzcujbczaasdvdqcky4p3gnzl4wstmvxal1avp2voa2qwvnmwfonvt0x0n6wbaudnmatbekhmduj8vvascr5fpkmf9rdjp5sy63evytcpnhns2crcx9sbmudlzfjwnfsku2bisq8mw n booking event cancel n source id pdr7 n booking id api bk58 n ; n nvar requestoptions n method delete n headers myheaders n body raw n redirect follow n ; n nfetch https api paydocker com version booking partnerid randomkey cancel requestoptions n then response response text n then result console log result n catch error console log error error ; customlabel id viti1rewoox nvrxgnltq language curl code curl location globoff request delete https api paydocker com version booking partnerid randomkey cancel n header accept application json n header content type application json n data share secret string booking event string source id string booking id string customlabel selectedlanguageid mq0bwfsdgkd5w06ldf55z results languages id zniey85b7bx38yo7mpqf0 language 200 customlabel code n success true n message booking cancel success n booking id 1705393126pdr28 n id 3x5 llsklcqy4ql7yfpv language 402 customlabel code n success false n errors n code 402 n message source not allowed n n id w6kfwaiol1p1nxyajoaq language 405 code n success false n errors n code 405 n message method not allowed n n customlabel id uuk3kuaibxsqfwyccsy6 language 403 code n success false n errors n code 403 n message ip not allowed n n customlabel id w8fkil7hsh6rpv8qg ctn language 406 code n success false n errors n code 406 n message endpoint bad format n n customlabel id kob8ifj9r uj0znvx ndp language 408 code n success false n errors n code 408 n message endpoint suspended n n customlabel id d21drpvlnwf4tvyiw icp language 409 code n success false n errors n code 409 n message event not allowed n n customlabel id h3xasfy0ynehiacw0mr8v language 410 code n success false n errors n code 410 n message invalid secret key n n customlabel selectedlanguageid w6kfwaiol1p1nxyajoaq 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 booking event kind required type string description used to identify the action connected to the booking and the allowed action for this request would be cancel 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 booking id kind required type string description the unique identifier associated with the booking that the user is requesting a cancellation for e g 1705393126pdr28 children formdataparameters currentnewparameter label body parameter value bodydataparameters