Skip to content

Annotate Invoice#

Annotate Invoice API is used to add an Annotation to the Invoice using the given request payload. This api Helps with collaboration between buyer and seller

Route

/invx/apis/{iridessa-version}/orgs/{org-id}/edocuments

- active 'iridessa-version': v1
- method: PATCH

URL Parameters#

Name Description Type
iridessa-version version of the API
for example, v1
string
org-id theodore organisation id string
doc-id document id string

Headers#

All headers are mentioned in common headers

Request#

Please refer the following request body for reference-

Sample request body

{
  "docId":"4b7f4aef-b23e-4e66-a982-6c44d21af976",
  "comments":"test annotation",
  "action":"ano"
}

Response#

Successful response will have the response in “data” attribute as a json.

200#

Sample response body

{
  "status": "1",
  "data": {
    "id": "d8fabae2-e809-4d2e-90f5-5c551832a437",
    "irn": null,
    "docNumber": "M14FE6164463F8ZA",
    "docType": "100",
    "docDate": "01/02/2022",
    "sellerGstin": "27AAAPI3182M002",
    "buyerGstin": "27ACBPN2353E1ZX",
    "irdDocType":"POST",
    "registeredOn": null,
    "ewbNo": null,
    "ewbDate" : null,
    "ewbValidTill" : null,
    "amount": 100,
    "acceptanceComments": null,
    "denialComments": null,
    "disputeComments": null,
    "cancellationComments": null,
    "cancellationReason": null,
    "status": "200",
    "createdByUserId": "76c747b5-79d4-4417-891b-f385a690250b",
    "createdOn": 1653013484020,
    "lastUpdatedByUserId": "76c747b5-79d4-4417-891b-f385a690250b",
    "lastUpdated": 1653013520149,
    "annotations": [
      {
        "annotation": "test annotation",
        "createByOrg": "5ae59d93-9292-425d-ad57-764da05d2262",
        "createBy": "76c747b5-79d4-4417-891b-f385a690250b",
        "createdOn": 1653013520160
      }
    ],
    "irnResponse" : null
  },
  "error": null,
  "info": null
}

400 BAD REQUEST#

Sample Response Body

{
  "error": {
    "message": "err-incorrect-update-action",
    "type": "ClientError",
    "args": {
      "message": "action ano on state 240.kotlin"
    }
  }
}

Note#

status field in document is the state of the Document generated. Different Document states are as bellow -

  • 100 -> DRAFT
  • 120 -> REGISTRATIONFAILED
  • 200 -> CREATED
  • 210 -> ACCEPTED
  • 220 -> DENIED
  • 230 -> DISPUTED
  • 240 -> CANCELLED
  • 250 -> FROZEN
  • 260 -> DELETE

Last update: April 7, 2023