Skip to main content
POST
/
v1
/
transactions
/
credit
Credit
curl --request POST \
  --url https://api.ecrypt.com/v1/transactions/credit \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "payment": {
    "token": "<string>",
    "stored": {
      "customer": "<string>",
      "wallet": "<string>",
      "installment": 123,
      "initialTransactionId": "<string>"
    },
    "terminal": {
      "id": "<string>",
      "externalIdentifier": "<string>",
      "promptTip": true,
      "tipAmounts": [
        123
      ],
      "promptCvv": true,
      "promptPostalCode": true,
      "promptAmountConfirmation": true,
      "promptSignature": true,
      "keyCard": true
    },
    "creditCard": {
      "accountNumber": "4111111111111111",
      "expires": "0135",
      "nameOnCard": "John Doe",
      "verificationValue": "000",
      "postalCode": "90210",
      "transactionId": "<string>"
    },
    "check": {
      "accountNumber": "<string>",
      "routingNumber": "<string>",
      "name": "<string>",
      "checkNumber": "<string>",
      "verification": {
        "dob": "<string>",
        "ssn": "<string>",
        "driversLicense": {
          "number": "<string>",
          "state": "<string>"
        }
      }
    },
    "cash": true,
    "creditCardEncrypted": "<string>",
    "googlePayPayment": {
      "signature": "<string>",
      "intermediateSigningKey": {
        "signedKey": "<string>",
        "signatures": [
          "<string>"
        ]
      },
      "protocolVersion": "<string>",
      "signedMessage": "<string>",
      "postalCode": "<string>",
      "nameOnCard": "<string>"
    }
  },
  "amount": {
    "value": 500000000
  },
  "order": {
    "customerPublicIdentifier": "<string>",
    "referenceObject": "<string>",
    "referenceObjectId": 123,
    "billTo": {
      "name": "<string>",
      "line1": "<string>",
      "line2": "<string>",
      "city": "<string>",
      "state": "<string>",
      "postalCode": "<string>",
      "country": "<string>"
    },
    "shipTo": {
      "name": "<string>",
      "line1": "<string>",
      "line2": "<string>",
      "city": "<string>",
      "state": "<string>",
      "postalCode": "<string>",
      "country": "<string>"
    },
    "discount": 123,
    "surcharge": 123,
    "shipping": 123,
    "email": "<string>",
    "tip": 123,
    "tax": 123,
    "total": 123,
    "date": "2023-11-07T05:31:56Z",
    "lines": [
      {
        "productCode": "<string>",
        "description": "<string>",
        "commodityCode": "<string>",
        "unitOfMeasure": "<string>",
        "unitCost": 123,
        "quantity": 123,
        "total": 123,
        "tax": 123,
        "taxRate": 123,
        "discount": 123,
        "discountRate": 123,
        "taxType": "<string>",
        "alternateTaxId": "<string>"
      }
    ],
    "metadata": {}
  },
  "initiatedByUserId": 123,
  "referenceTransactionId": 123
}
'
{
  "requestId": "000000000000000000000",
  "transactionId": "<string>",
  "authCode": "<string>",
  "responseCode": "<string>",
  "responseText": "<string>",
  "latency": 123,
  "avs": {
    "code": "<string>",
    "text": "<string>"
  },
  "cvv": {
    "code": "<string>",
    "text": "<string>"
  },
  "amount": 123,
  "metadata": {},
  "errors": [
    {
      "type": "<string>",
      "message": "<unknown>"
    }
  ]
}

Authorizations

x-api-key
string
header
required

Authorization by x-api-key inside request's header

Body

payment
object

Payment requires that you submit only one of the below options:

  • Token
  • Stored
  • Terminal,
  • Check
  • Cash
amount
object
order
object
initiatedByUserId
integer<int64> | null
referenceTransactionId
integer<int64> | null

Response

object | null

OK

requestId
string
default:000000000000000000000
required
Required string length: 1 - 100
transactionId
string
authCode
string
responseCode
string
responseText
string
latency
integer<int32>
avs
object
cvv
object
amount
number<decimal>
metadata
object
errors
(object | null)[] | null