eCMRhub.docs
API referenceApprovals

List approvals

GET
/functions/v1/approvals

Approvals newest first, optionally by status. A person sees the whole company's; an OAuth connection or an API key sees only its own.

Authorization

apikeybearerAuth
headerapikey<token>
headerAuthorizationBearer <JWT>

Query Parameters

status?string
Value in"pending""approved""rejected""consumed""expired"

Response Body

Success

application/json
  1. response
items*array<>
Example Request
curl -X GET 'https://api-ecmr-dev.lucaspiera.com/functions/v1/approvals'
Example Response
{  "items": [    {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "operation": "string",      "status": "pending",      "requestedBy": {        "connectionId": "84b500d7-71c8-4b1f-adf4-f1eb0000973d",        "name": "string"      },      "summary": {        "subject": "string",        "action": "string",        "items": [          {            "id": "string"          }        ],        "batch": {          "total": 0        },        "includesSave": true      },      "input": {        "property1": null,        "property2": null      },      "url": "string",      "createdAt": "2019-08-24T14:15:22Z",      "decidedAt": "2019-08-24T14:15:22Z",      "decidedBy": "string",      "expiresAt": "2019-08-24T14:15:22Z"    }  ]}