Thedex
  • Introduction
    • Merchant Payment Gateway
    • Currencies and networks
    • Confirmations and limits
  • Documentation
    • API Overview
    • Invoices
      • Create full invoice
      • Define full invoice crypto-currency
      • Create quick crypto invoice
      • Create quick fiat invoice
      • Get Invoice
      • Get invoices
      • Create static wallet
      • Get static wallet
      • Deprecated
        • Create quick invoice
    • Payouts
      • Create a payout
      • Create fiat-to-crypto payout
      • Get payout
      • Get payouts
    • Swaps
      • Get swaps
    • Balances
      • Get all user balances
    • Informational
      • Get status definitions for Invoice and payout
      • Get active crypto and fiat currencies
      • Get cryptocurrency to fiat-currency rate
      • Get fiat currency amount limits on invoice creation
      • Get fiat currency amount limits on payout creation
      • Get cryptocurrency amount limits on invoice creation
      • Get cryptocurrency amount limits on payout creation
      • Get Invoice creation ways
    • Commissions
      • Get payout commissions
      • Get invoice commissions
    • Merchant Preferences
      • Get merchant wallet whitelist
      • Add wallet to whitelist
      • Remove wallet to whitelist
  • E-Commerce plugins
    • WHMCS
Powered by GitBook
On this page
  1. Documentation
  2. Invoices
  3. Deprecated

Create quick invoice

PreviousDeprecatedNextPayouts

Last updated 4 months ago

Note: This method is deprecated. Please use instead.

POST https://app.thedex.cloud/api/v1/invoices/create/quick

Headers

Name
Type
Description

X-EX-APIKEY*

String

Your API key

X-EX-PAYLOAD*

String

Body to base64

X-EX-SIGNATURE*

String

Encrypted body with the secret key

Request Body

Name
Type
Description

amount*

BigDecimal

To check minimal limit amount, use: api/v1/info/invoice/limit/crypto

payCurrency*

String

merchantId*

String

Merchant ID

You can find it on page 'Merchants' in your account

orderId

String

Order ID in your system

email

String

clientId

String

ID of your client

title

String

max size = 50

description

String

max size = 300

recalculation

boolean

Default = false

If recalculation = false, the invoice will be expecting a payment that is equal to or greater than 'amountInPayCurrency'

'amountInPayCurrency' and 'merchantBalance' of invoice will not be recalculated in the case of

Successfulstatus. If client send amount that less than 'amountInPayCurrency' status of invoice will be Underpaid

If recalculation = true, the invoice will be expecting a payment that is equal to or greater than 'amountInPayCurrency'

'amountInPayCurrency' and 'merchantBalance' of invoice will be recalculated in the case of

Successfulstatus. If the client send amount that is less than 'amountInPayCurrency' status of invoice will be Underpaid

Reach out all available invoice statuses by endpoint:

successUrl

String

Custom successUrl for an invoice, that can be differ from merchant settings

failureUrl

String

Custom failureUrl for an invoice, that can be differ from merchant settings

callbackUrl

String

Custom callbackUrl for an invoice, that can be differ from merchant settings

unfixAmount

boolean

Default = false

If unfixAmount = true, the amount of the invoice will be unfixed, so the client can send any amount, and 'amountInPayCurrency' will be recalculated. In this case, only one transaction is allowed to pay.

If unfixAmount = true, the flow of processing invoice will be as recalculation parameter setting

generateQr

boolean

Default = false If generateQr =true, a QR code will be generated for the invoice. The response will include both qrBase64 (a base64-encoded image of the QR code) and qrUrl (a direct link to the QR image).

{
   "invoiceId": "String",
   "merchantId": "String",
   "clientId": "String",
   "orderId": "String",
   "purse": "String",
   "payCurrency": "String",
   "blockchainFee": "String",
   "amountInPayCurrency": "String",
   "createDate": "String",
   "modifiedDate": "String",
   "status": "Integer",
   "payUrl": "String"
}

Curl request:

curl --location 'https://app.thedex.cloud/api/v1/invoices/create/quick' \
--header 'X-EX-APIKEY: <string>' \
--header 'X-EX-PAYLOAD: <string>' \
--header 'X-EX-SIGNATURE: <string>' \
--header 'Content-Type: application/json' \
--header 'Accept: */*' \
--data '{
  "amount": "<number>",
  "clientId": "<string>",
  "payCurrency": "<string>",
  "description": "<string>",
  "email": "<string>",
  "merchantId": "<string>",
  "orderId": "<string>",
  "recalculation": "<boolean>",
  "unfixAmount": "<boolean>",
  "title": "<string>",
  "successUrl": "<string>",
  "failureUrl": "<string>",
  "callbackUrl": "<string>"
}'

Response JSON attributes:

"invoiceId"

String

Invoice id

"merchantId"

String

Merchant Id

"orderId"

String

Order id

"clientId"

String

Client id

"purse"

String

Purse (crypto wallet)

"payCurrency"

String

Pay currency (crypto currency)

"blockchainFee"

String

Deposit blockchain fee

"amountInPayCurrency"

String

Amount in crypto currency

"createDate"

String

Creation date

"modifiedDate"

String

Modification date

"createTimestamp"

Long

Creation date in milliseconds

"modifiedTimestamp"

Long

Modification date in milliseconds

"expirationTimestamp"

Long

Expiration date in milliseconds

"status"

Integer

"payUrl"

String

Pay Url

"qrBase64"

String

Optional

QR base64-encoded image of the QR code

"qrUrl"

String

Optional Link to the QR image

Reach out all available crypto currencies by endpoint:

Used as additional details for invoice. Or required in couple with field "needsEmailConfirmation". In the second case, this email will receive confirmation link, necessary to get access to mentioned in

reach out all accessed values by link:

Create quick crypto invoice
/api/v1/info/currencies
"Steps to complete and read the invoice using email confirmation".
“Define invoice currency”
/api/v1/info/statuses
/api/v1/info/statuses