Refill Postage Account

HTTP Request

POST /v1/developers/{developerId}/merchants/{postalReportingNumber}/account/fund

Summary

This operation lets a merchant add funds to a PB Postage Account. The operation performs a one-time refill, separate from the automatic refill process. The operation refills the merchant’s postage account using the payment method on file.

Note: Merchants can also perform refills through the Merchant Portal.

See also:

Request URLs

Sandbox: https://shipping-api-sandbox.pitneybowes.com/shippingservices/v1/developers/{developerId}/merchants/{postalReportingNumber}/account/fund
Production: https://shipping-api.pitneybowes.com/shippingservices/v1/developers/{developerId}/merchants/{postalReportingNumber}/account/fund

Path Parameters

Name

Description

developerId


Required. Your Pitney Bowes developer ID. To retrieve your developer ID, log into Developer Hub and click your username and select Profile.

postalReportingNumber

Required. The unique ID used to identify the merchant. To retrieve the merchant’s postalReportingNumber, issue the Get Merchant Accounts API call.

Request Headers

Name


Description

Authorization

Required. OAuth token generated using the Generate an OAuth Token API.

Content-Type

Required. The media type of the request entity. Set this to application/json.

Accept-Language

Language and country code. Default: en-US

X-PB-TransactionId

Required. A unique identifier for the transaction, up to 25 characters. The following characters are allowed: letters, numbers, hyphens (-), and underscores (_).

Important: Ensure this is a unique ID.

X-PB-UnifiedErrorStructure

Recommended. Set this to true to use the standard error object if an error occurs.

Request / Response Elements

Name

Data Type

Description

amount

Integer

Required. The amount to add to the merchant’s PB Postage Account. You must enter the amount as an integer.

currencyCode

String

Required. ISO Currency Code. Currently supported currency code: USD

Sample Request

curl -X POST ".../v1/developers/<developer_id>/merchants/<postal_reporting_number>/account/fund" \
-H "Authorization: Bearer <oauth_token>" \
-H "Content-Type: application/json" \
-H "X-PB-TransactionId: 2805501872" \
-H "isErrorUnified: true" \
-d '
{
    "amount": 500,
    "currencyCode": "USD"
}'

Sample Response

{
    "amount": 500,
    "currencyCode": "USD"
}

Error Codes

For a list of all error codes returned by the Ecommerce APIs, please see Error Codes.