Server to Server Management APIs
Payments

Payments

Get Payments

GET /payments

Request

Get payment list

Authentication

  • authToken in header

Parameters

  • offset in query - number
    Pagination offset
  • limit in query - number
    Pagination limit
  • orderBy in query - string
    "DESC" or "ASC"
    Example: DESC

    Allowed: DESC | ASC

  • sortBy in query - string
    Sort by the field value
    Example: createdAt

    Allowed: moduleName | processingStatus | appliedStatus | createdAt | customerId | externalCustomerId | fundingStatus | updatedAt | totalAmount

  • searchBy in query - string
    Filter by a field

    Allowed: id | customerId | externalId | externalCustomerId

  • q in query - string
    You can perform keyword queries on fields corresponding to the value of "searchBy" or, if "searchBy" is empty, on all fields supported by "searchBy".
  • customerName in query - string
    Query by invoice B2B Edition company name
  • invoiceId in query - number
    Query by Invoice ID
  • processingStatus in query - number
    payment processing status(0="Incomplete", 1="Awaiting Processing", 2="Processing", 3="Completed", 4="Refunded")
    Example: 3

    Allowed: 0 | 1 | 2 | 3 | 4

  • channelIds in query - array
    Query by BigCommerce Channel IDs. This parameter is not needed if you don't have multiple storefront channels.
    Type: array[number]

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    array[object]
    required

  • meta
    object
    required

200

Get Payment Detail

GET /payments/{paymentId}

Request

Get payment detail

Authentication

  • authToken in header

Parameters

  • paymentId in path - number
    required
    Payment ID

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

200

Delete a Payment

DELETE /payments/{paymentId}

Request

Delete a payment

Authentication

  • authToken in header

Parameters

  • paymentId in path - number
    required
    Payment ID

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

200

Get a Payment Operation

GET /payments/{paymentId}/operations

Request

Get a payment for all operations

Authentication

  • authToken in header

Parameters

  • paymentId in path - number
    required
    Payment ID

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

200

Performing Payment Operation

POST /payments/{paymentId}/operations

Request

Performing payment operation

Authentication

  • authToken in header

Parameters

  • paymentId in path - number
    required
    Payment ID

Body

object | application/json
  • operationCode
    number
    required

    Payment operation code. The list of allowed operations for this payment.

    Allowed: 0 | 1 | 2 | 3

200

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

200

Update Payment Processing Status

PUT /payments/{paymentId}/processing-status

Request

Update payment processing status

Authentication

  • authToken in header

Parameters

  • paymentId in path - number
    required
    Payment ID

Body

object | application/json
  • processingStatus
    number
    required

    payment processing status(1="Awaiting Processing", 2="Processing", 3="Completed", 4="Refunded")

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

200

Get Payment Transactions

GET /payments/{paymentId}/transactions

Request

Get payment transactions

Authentication

  • authToken in header

Parameters

  • paymentId in path - number
    required
    Payment ID

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    array[object]
    required

    The array contains payment transaction information that varies and depends on the payment gateway.
  • meta
    object
    required

200

Create Offline Payment

POST /payments/offline

Request

Create offline payment

Authentication

  • authToken in header

Body

object | application/json
  • lineItems
    array[object]
    required

  • currency
    string
    required

  • details
    object
    required

  • externalId
    string

  • customerId
    string
    required

    B2B Edition Company ID
  • externalCustomerId
    string

  • payerName
    string

    Default is "Store Offline Payment " if no value is passed in.

    Default: Store offline payment

  • payerCustomerId
    string

    The default value is the same as the customerId.
  • processingStatus
    number

    payment status, 3 is the default

    Allowed: 1 | 2 | 3 | 4

    Example: 3

    Default: 3

  • channelId
    integer

    BigCommerce channel ID

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

200

Update an Offline Payment

PUT /payments/offline/{paymentId}

Request

Update offline payment

Authentication

  • authToken in header

Parameters

  • paymentId in path - number
    required
    Payment ID

Body

object | application/json
  • lineItems
    array[object]
    required

  • currency
    string
    required

  • details
    object
    required

  • externalId
    string

  • customerId
    string
    required

    B2B Edition Company ID
  • externalCustomerId
    string

  • payerName
    string

    Default is "Store Offline Payment " if no value is passed in.

    Default: Store offline payment

  • payerCustomerId
    string

    The default is the same as the customerId.
  • processingStatus
    number

    Allowed: 1 | 2 | 3 | 4

    Example: 3

    Default: 3

  • fundingStatus
    number

    Allowed: 0 | 1 | 2 | 3

    Default: 2

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

200

Did you find what you were looking for?