Skip to main content

Custom Operations

NOTICE

Custom operations are optional. I.e. the service-provider may not define any custom operations at all.

Mandatory Standards for Variables

In order to maintain company-wide standards, BOG requires that service-providers use specific variable names that correspond with their respective meaning. E.g. if a customer uses their personal number to receive some information (e.g. debt) from the service-provider, then the latter must use personalNumber as the name of the variable required by the API.

View the full list of mandatory variable standards below:

  • personalNumber – used as a personal number identifier.
  • customerId – used as a customer identifier.
  • debt – the amount owed by the customer to the service-provider in minor units.
  • debtList – A list of data models that contain the amounts (and possibly other fields) owed by the customer to the service-provider in minor units.
  • amount – the amount that the customer is willing to pay in minor units.

Data Exchange Format

All custom operations that communicate with the service provider’s API will send all request parameters as query parameters,along with the header values used for authentication. The service provider must respond with a pre-defined format for each operation:

status.codenumber

Refers to the pre-defined status codes.

status.valuestring

Status value (optional)

timestampnumber

UNIX timestamp – the amount of milliseconds that have passed since January 1st, 1970 at UTC .

receiptIdstring

receiptId is a unique identifier of the payment, returned from the service-provider after a successful payment operation (optional).

responseobject

The JSON data returned from some arbitrary operation. It is required for every custom operation.

{
"status":{
"code":0,
"value":"OK"
},
"timestamp":1693236686855,
"receiptId":"",
"response":{"wrapper":{"categoryCodes":["A1","B"]}}
}
note

Along with the custom operations created by the service-provider, there also exist pre-defined operations by BOG, from which only the Payment operation is required, all others are optional.