Update Delivery Method

The UpdateDeliveryMethod API is used to update the delivery method of a payer in OCS.io.

The attribute Delivery Method in the OCS.io is not versioned. Any changes to this attribute take effect immediately upon update. Please note that these changes do not have a retrospective effect, meaning they do not alter the delivery methods of documents that were created prior to the update.

API Overview

Fields Required for Updating Delivery Method

The following table lists and describes the fields required to update the delivery method through the UpdateDeliveryMethod API:

Field Description

account

ID (Ref ID/ External ID ) of the Account.

deliveryMethod

DeliveryMethod assigned to Account. Delivery Method must be configured.

documentType

Type of the Document for which Delivery Method is updated. If null, Delivery Method is valid for all document types. Document Type must be configured.

Detailed API documentation and endpoint specifics are available here.

Request Validations

The following validations are performed when updating the delivery method:

  • Account must be provided in the request, it must be already created in the system and must not be in Deactivated State.

  • Payer must be already created in the system.

Update Delivery Method Example

Use the following request’s body to update a delivery method:

{
  "requestId": "{{$guid}}",
  "user": "crm",
  "account": {
    "externalId": "account_external_id"
  },
  "deliveryMethod": "delivery_method_code",
  "documentType": "document_type_code"
}

The outcome of the API call is as follows:

  • It is validated, that the account with External ID account_external_id exists

  • The delivery method for the account is updated to configured delivery method with code delivery_method_code

  • The update is applicable for the configured document type with code document_type_code