The internal identifier of the schedule. Required only for updates.
Adfin API (1.0.0)
Adfin uses OAuth 2.0 access tokens to authenticate all API requests.
There are two contexts in which tokens are issued:
Biller Access Tokens — Generated via the Authorization Code flow when a biller connects their Adfin account. These tokens grant access to that biller's data (invoices, payment requests, customers, etc.).
Platform Access Tokens — Generated via the Client Credentials flow when a platform authenticates as itself rather than as one of its billers. A platform uses one to manage its own webhook subscriptions under
/api/apps/{clientId}/webhooks.
The internal id of the template to be used for defining the schedule. Can be used in place of defining individual events for a schedule; in this case, the events will be automatically copied from the template. This streamlines the process and ensures consistency across schedules.
The name of the schedule to be created for the customer. It must contain only alphanumeric characters, and be limited to a maximum of 50 characters.
The type of the schedule to be created for the customer
A list of events that will occur as part of the schedule, applicable exclusively to a single customer
- Mock serverhttps://developer.adfin.com/_mock/products/direct-integration/direct-integration-api-reference/workflows
- Production API Server URLhttps://api.adfin.com/api/workflows
- Staging API Server URLhttps://api.staging.adfin.com/api/workflows
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
https://developer.adfin.com/_mock/products/direct-integration/direct-integration-api-reference/workflows \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"id": "string",
"templateId": "string",
"customerDetails": {
"id": "string",
"name": "string"
},
"invoiceDetails": {
"id": "string",
"invoiceNo": "string",
"description": "string",
"totalAmount": "string",
"taxAmount": "string",
"dueAmount": "string",
"creditNotesAmount": "string",
"dueDate": "2019-08-24T14:15:22Z",
"issueDate": "2019-08-24T14:15:22Z",
"creationTime": "2019-08-24T14:15:22Z",
"lastUpdatedTime": "2019-08-24T14:15:22Z",
"paidTime": "2019-08-24T14:15:22Z",
"status": "DRAFT",
"statusReasonCode": "MISSING_PAYER_CONTACT_DETAILS",
"statusReason": "string",
"itemsTaxType": "EXCLUSIVE",
"items": [
{
"id": "string",
"description": "string",
"quantity": 0,
"unitAmount": 0,
"taxRate": 0,
"taxAmount": 0,
"totalAmount": 0,
"taxDetails": {
"id": "string",
"rate": 0
},
"accountDetails": {
"id": "string",
"code": "string"
},
"productDetails": {
"id": "string",
"code": "string"
},
"externalData": [
{
"id": "string",
"connectorType": "XERO",
"templateId": "string",
"accountCode": "string",
"groupLineId": "string"
}
],
"trackingItems": [
{
"id": "string",
"name": "string"
}
]
}
],
"creditNotes": [
{
"id": "string",
"number": "string",
"amount": 0,
"valueDate": "2019-08-24T14:15:22Z",
"externalData": [
{
"connectorType": "XERO",
"id": "string"
}
]
}
],
"fileSource": "NONE",
"invoiceSource": "FILE_UPLOAD",
"externalData": [
{
"connectorType": "XERO",
"id": "string",
"brandingThemeId": "string"
}
]
},
"name": "string",
"type": "ONE_TIME_PAYMENT",
"customMessage": "string",
"events": [
{
"frequency": {
"timeUnit": "MONTH, WEEK, DAY",
"frequency": 0,
"dayOfMonth": 0
},
"duration": {
"startDate": "2019-08-24T14:15:22Z",
"endDate": "2019-08-24T14:15:22Z",
"maxNoOfExecutions": 0
},
"trigger": {
"days": 0,
"operator": "ON",
"referenceDate": "DUE_DATE"
},
"relativeDateTrigger": {
"days": 0,
"operator": "ON",
"referenceDate": "DUE_DATE"
},
"ordinalWeekdayTrigger": {
"ordinal": 0,
"dayOfWeek": "string"
},
"type": "NO_ACTION",
"details": null
}
],
"settings": {
"customerStatementSettings": {
"minOutstandingBalance": 0,
"minOverdueDays": 0
}
}
}'The request was successful, resulting in the creation of one workflow.
The internal id of the template used to define the workflow. This template id has been utilized to automatically copy events into the instance, streamlining the process and ensuring consistency throughout
Attribute that specifies the type of workflow
The current state of the workflow
The list of events that will occur as part of the workflow, applicable exclusively to a single customer
{ "id": "string", "templateId": "string", "customerDetails": { "id": "string", "name": "string" }, "invoiceDetails": { "id": "string", "invoiceNo": "string", "description": "string", "totalAmount": "string", "taxAmount": "string", "dueAmount": "string", "creditNotesAmount": "string", "dueDate": "2019-08-24T14:15:22Z", "issueDate": "2019-08-24T14:15:22Z", "creationTime": "2019-08-24T14:15:22Z", "lastUpdatedTime": "2019-08-24T14:15:22Z", "paidTime": "2019-08-24T14:15:22Z", "status": "DRAFT", "statusReasonCode": "MISSING_PAYER_CONTACT_DETAILS", "statusReason": "string", "itemsTaxType": "EXCLUSIVE", "items": [ … ], "creditNotes": [ … ], "fileSource": "NONE", "invoiceSource": "FILE_UPLOAD", "externalData": [ … ] }, "name": "string", "type": "ONE_TIME_PAYMENT", "state": "DRAFT", "paymentInitiationDate": "2019-08-24T14:15:22Z", "creationTime": "2019-08-24T14:15:22Z", "lastUpdatedTime": "2019-08-24T14:15:22Z", "events": [ { … } ], "settings": [ { … } ], "workflowSettings": { "reminderSettings": [ … ], "customerStatementSettings": { … } }, "autopilotReasoning": "string" }