TEMPLATES

A Template is a pre defined message format which can be called over and again, without requiring to rewrite again.

CREATE TEMPLATE

This endpoint allows you to create a template

POST https://squadbygtco.com:8080/dashboard/template

Request Body

Name
Type
Description

name*

String

Name of the template

body*

String

Actualt template form to be used continiously

Client_id*

Integer

Unique Client ID pre-assigned

description*

String

Description of template

Sample Request

{
    "name": "CHDP_C",
    "body": "Txn: Credit\nAc:#$TXN_ACC$#\nAmt:#$AMOUNT$#\nDes:Cash Dep/_BRC_/#$OFS_ACC$#/#$TRANSACTION_ID$#\nDate:#$TXN_DATE$#\nBal#$CCY$##$AVAIL_BAL$#\n#$sms_advert#",
    "client_id": 2,
    "description":"CASH DEPOSIT CREDITING"
}
{
    "status": "CREATED",
    "message": "template created successfully",
    "data": {
        "id": 5,
        "name": "CHDP_C",
        "description": "CASH DEPOSIT CREDITING",
        "client_id": 2,
        "created_at": "2024-04-08T13:02:44.000Z",
        "created_by": 1,
        "updated_at": null,
        "updated_by": null
    }
}

GET ALL CREATED TEMPLATES

This endpoint allows you to retrieve all created templates

GET https://squadbygtco.com:8080/dashboard/template/by-client/2?page=1&count=10

UPDATE CREATED TEMPLATES

This endpoint allows you to edit the body of a template.

PATCH https://squadbygtco.com:8080/dashboard/template/3

Sample Request

DELETE CREATED TEMPLATE

This endpoint allows you to delete a template

DELETE https://squadbygtco.com:8080/dashboard/bucket/1

Sample Response

Last updated

Was this helpful?