Paycose Docs
E2ECreate Quotes
POST/quotes

Shipping address override (USD)

Per-quote shipping_address override.

Request

Example

curl -X POST 'https://api.paycose.com/api/v1/app1/platform/wallet/quotes/' \
  -H 'X-Session-Token: {{session_token}}' \
  -H 'X-Country: {{country}}' \
  -H 'X-Test-Mode: {{x_test_mode}}' \
  -d '{
  "line_items": [
    {
      "product_id": "{{e2e_product_logitech_mx3s}}",
      "quantity": 1
    }
  ],
  "default_tax_rates": [],
  "default_fees": [],
  "coupon": "",
  "customer_id": "{{e2e_customer_us_individual}}",
  "default_payment_method": {
    "id": "<string>",
    "type": "<string>"
  },
  "collection_method": "<string>",
  "capture_method": "<string>",
  "auto_advance": false,
  "due_date": "<RFC3339 timestamp>",
  "currency": "USD",
  "transfer_data": {
    "destination": "{{e2e_customer_destination}}",
    "balance_id": "{{e2e_balance_usd}}"
  },
  "metadata": {
    "scenario": "shipping-address-override"
  },
  "account_tax_ids": [
    "<string>"
  ],
  "payment_method_types": [
    "<string>"
  ],
  "payment_method_providers": [
    "<string>"
  ],
  "shipping_address": {
    "name": "Mary Johnson (Office)",
    "phone": "+14155550199",
    "line1": "1 Apple Park Way",
    "line2": "MS 169-1AP",
    "city": "Cupertino",
    "state": "CA",
    "postal_code": "95014",
    "country": "US"
  },
  "shipping_rate_id": "{{e2e_ship_dhl_intl}}",
  "enable_shipping": false,
  "labels": [
    "<string>"
  ]
}'

Headers

NameValueDescription
X-Session-Token{{session_token}}
X-Country{{country}}
X-Test-Mode{{x_test_mode}}true=wallet_test, false=wallet_live (default). Toggle the x_test_mode collection variable to flip every applicable request.

Body

NameTypeValue
line_itemsarray[1]
default_tax_ratesarray[0]
default_feesarray[0]
couponstring
customer_idstring{{e2e_customer_us_individual}}
default_payment_methodobject{…}
collection_methodstring<string>
capture_methodstring<string>
auto_advancebooleanfalse
due_datestring<RFC3339 timestamp>
currencystringUSD
transfer_dataobject{…}
metadataobject{…}
account_tax_idsarray[1]
payment_method_typesarray[1]
payment_method_providersarray[1]
shipping_addressobject{…}
shipping_rate_idstring{{e2e_ship_dhl_intl}}
enable_shippingbooleanfalse
labelsarray[1]
{
  "line_items": [
    {
      "product_id": "{{e2e_product_logitech_mx3s}}",
      "quantity": 1
    }
  ],
  "default_tax_rates": [],
  "default_fees": [],
  "coupon": "",
  "customer_id": "{{e2e_customer_us_individual}}",
  "default_payment_method": {
    "id": "<string>",
    "type": "<string>"
  },
  "collection_method": "<string>",
  "capture_method": "<string>",
  "auto_advance": false,
  "due_date": "<RFC3339 timestamp>",
  "currency": "USD",
  "transfer_data": {
    "destination": "{{e2e_customer_destination}}",
    "balance_id": "{{e2e_balance_usd}}"
  },
  "metadata": {
    "scenario": "shipping-address-override"
  },
  "account_tax_ids": [
    "<string>"
  ],
  "payment_method_types": [
    "<string>"
  ],
  "payment_method_providers": [
    "<string>"
  ],
  "shipping_address": {
    "name": "Mary Johnson (Office)",
    "phone": "+14155550199",
    "line1": "1 Apple Park Way",
    "line2": "MS 169-1AP",
    "city": "Cupertino",
    "state": "CA",
    "postal_code": "95014",
    "country": "US"
  },
  "shipping_rate_id": "{{e2e_ship_dhl_intl}}",
  "enable_shipping": false,
  "labels": [
    "<string>"
  ]
}

Responses

200200 OK

Headers

NameValue
Content-Typeapplication/json

Body

{
  "id": "<string>",
  "object": "<string>",
  "resource": "<string>",
  "created_at": "<RFC3339 timestamp>",
  "errors": [
    {
      "code": "<string>",
      "message": "<string>"
    }
  ],
  "next_action": [
    {
      "type": "<string>",
      "title": "<string>",
      "description": "<string>",
      "i18n_key": "<string>",
      "url": "<string>",
      "client_secret": "<string>",
      "payment_method": "<string>",
      "qr_data": "<string>"
    }
  ]
}
400400 Bad Request

Headers

NameValue
Content-Typeapplication/json

Body

{
  "object": "error",
  "code": "<string>",
  "key": "<string>",
  "i18n_key": "<string>",
  "message": "<string>",
  "request_id": "<string>"
}
500500 Internal Server Error

Headers

NameValue
Content-Typeapplication/json

Body

{
  "object": "error",
  "code": "<string>",
  "key": "<string>",
  "i18n_key": "<string>",
  "message": "<string>",
  "request_id": "<string>"
}

On this page