Experimental Create a cashier deposit request

Creates a cashier deposit request. To complete the deposit, the customer is redirected to the cashier link. After the deposit, the customer is redirected to the redirectUrl. Corresponding transaction webhooks are sent to webhooks subscribers.

SecuritySecretApiKey or JWT
Request
Request Body schema: application/json

Cashier request resource.

websiteId
required
string <= 50 characters

Website ID of the cashier. This value specifies the website with which the cashier is associated.

customerId
required
string (CustomerId) <= 50 characters

ID of the customer resource.

strategyId
string <= 50 characters

ID of a strategy to be applied for this request for amounts and customAmount. If this field is not specified, a randomly selected strategy with a matching filter value is applied for empty amounts and customAmount.

currency
required
string (CurrencyCode) = 3 characters

Currency code in ISO 4217 format.

amounts
Array of numbers <double>

List of available deposit amounts.

If amounts is not specified when a cashier is created, amounts are determined from the chosen strategy. For more information, see the strategyId property.

object or null (CashierStrategyCustomAmount)

Custom amount restrictions. If this value is null, custom amounts are prohibited. If customAmount is not specified when a cashier is created, amount restrictions are determined from the chosen strategy. For more information, see the strategyId property.

redirectUrl
string <uri>

URL to redirect the customer to when a deposit is completed. The default value is the website URL.

expirationTime
string <date-time>

Date and time at which the cashier request expires. The default expiration time is one hour from the time the request is created.

customPropertySetId
string <= 50 characters

ID of a custom property set to apply to the request propertiesSchema.

Responses
201

Cashier request created.

Response Headers
Location
string <uri>

Location of the related resource.

Example: "https://api.rebilly.com/example"
Response Schema: application/json
id
string <= 50 characters

ID of the cashier deposit request.

websiteId
required
string <= 50 characters

Website ID of the cashier. This value specifies the website with which the cashier is associated.

customerId
required
string (CustomerId) <= 50 characters

ID of the customer resource.

transactionId
string or null <= 50 characters

ID of the transaction that is used in the cashier request.

status
string

Status of the request.

Enum: Description
created

Request is created, but it has not been visited by a customer. This is a temporary state.

pending

Request has been visited by a customer, but no funds have been deposited yet. This is a temporary state.

completed

A funds deposit transaction has been initiated. This is a permanent state.

expired

Request expired without a deposit attempt. This is a permanent state.

currency
required
string (CurrencyCode) = 3 characters

Currency code in ISO 4217 format.

amounts
Array of numbers <double>

List of available deposit amounts.

If amounts is not specified when a cashier is created, amounts are determined from the chosen strategy. For more information, see the strategyId property.

object or null (CashierStrategyCustomAmount)

Custom amount restrictions. If this value is null, custom amounts are prohibited. If customAmount is not specified when a cashier is created, amount restrictions are determined from the chosen strategy. For more information, see the strategyId property.

redirectUrl
string <uri>

URL to redirect the customer to when a deposit is completed. The default value is the website URL.

expirationTime
string <date-time>

Date and time at which the cashier request expires. The default expiration time is one hour from the time the request is created.

propertiesSchema
object

Defines properties the user can complete when they use the hosted cashier form. This field accepts JSON-schema drafts 4, 6, and 7.

object

Properties that are available for the user to complete when they use the hosted cashier form. Use this object to describe fields that are rendered and completed during the deposit process, in the cashier deposit form.

createdTime
string <date-time> (CreatedTime)

Date and time which is set automatically when the resource is created.

updatedTime
string <date-time> (UpdatedTime)

Date and time which updates automatically when the resource is updated.

Array of objects

Related links.

object

Embedded objects that are requested by the expand query parameter.

401

Unauthorized access. Invalid credentials used.

403

Access forbidden.

422

Invalid data sent.

post/cashier-requests
Request samples
application/json
{
  • "websiteId": "web_0YV7DE4Z26DQSA1AC92FBJ7SEG",
  • "customerId": "cus_0YV7DDSDD1C8DA64KHH2W33CPF",
  • "strategyId": "4f6cf35x-2c4y-483z-a0a9-158621f77a21",
  • "currency": "USD",
  • "amounts": [
    ],
  • "customAmount": {
    },
  • "redirectUrl": "http://example.com",
  • "expirationTime": "2019-08-24T14:15:22Z",
  • "customPropertySetId": "4f6cf35x-2c4y-483z-a0a9-158621f77a21"
}
Response samples
application/json
{
  • "id": "cash_req_0YVJ65BSGYC3EAT58SEX8KY6J7",
  • "websiteId": "web_0YV7DE4Z26DQSA1AC92FBJ7SEG",
  • "customerId": "cus_0YV7DDSDD1C8DA64KHH2W33CPF",
  • "transactionId": "4f6cf35x-2c4y-483z-a0a9-158621f77a21",
  • "status": "created",
  • "currency": "USD",
  • "amounts": [
    ],
  • "customAmount": {
    },
  • "redirectUrl": "http://example.com",
  • "expirationTime": "2019-08-24T14:15:22Z",
  • "propertiesSchema": {
    },
  • "properties": {
    },
  • "createdTime": "2019-08-24T14:15:22Z",
  • "updatedTime": "2019-08-24T14:15:22Z",
  • "_links": [
    ],
  • "_embedded": {
    }
}