Approved clients

Approved Clients

This endpoint returns the number of approved clients within a specified date range. It is designed to support dashboard widgets and reporting tools by summarizing client approval counts across banking and merchant categories. Optional filters allow narrowing results by agent IDs, ISO ID, or profile IDs.

Endpoint

POST /api/Widget/approved

Authentication

Bearer token required. Obtain via:

POST https://api.banking.netevia.dev/api/auth/v2

Include in header: Authorization: Bearer {token}
Token lifetime: 10 minutes. Refresh via POST /api/auth/refresh.

When to use

Use this endpoint to populate partner dashboard widgets that display approved client counts over a rolling period. The typical use case is to retrieve data for the last three months (including the current month), so set fromDate to the first day of the earliest month in the desired range and toDate to the current date. Apply the optional filters when the dashboard supports scoping results to a specific agent, ISO, or partner profile.

Request Body

FieldTypeRequiredDescription
fromDatestring (date-time)YesStart of the date range. Set to the first day of the earliest month in the desired range (ISO 8601 format).
toDatestring (date-time)YesEnd of the date range. Typically set to the current date and time (ISO 8601 format).
agentsIdarray of integersNoList of agent IDs to filter results. Omit to include all agents.
isoIdintegerNoISO ID to filter results. Omit to include all ISOs.
profileIdsarray of integersNoList of profile IDs to filter results. Omit to include all profiles.
{
  "fromDate": "2024-08-01T00:00:00Z",
  "toDate": "2024-10-15T23:59:59Z",
  "agentsId": [101, 102],
  "isoId": 5,
  "profileIds": [201, 202, 203]
}

Response

200 OK

FieldTypeDescription
bankingCountinteger or nullNumber of approved banking clients within the specified date range and filters.
merchantCountinteger or nullNumber of approved merchant clients within the specified date range and filters.
{
  "bankingCount": 47,
  "merchantCount": 23
}

Error Codes

CodeWhen it happens
400Missing required fields (fromDate or toDate) or invalid date format
401Token missing, expired, or invalid
403Insufficient permissions to access widget reporting data
404Resource not found
500Internal server error

Common Mistakes

  • Omitting fromDate or toDate — both are required; the request will return a 400 error if either is missing.
  • Using a date format other than ISO 8601 (e.g., MM/DD/YYYY) — always use YYYY-MM-DDTHH:MM:SSZ format.
  • Setting fromDate later than toDate — the range must be chronologically valid or results will be empty or an error will be returned.
  • Expecting the response to include partial-month data for toDate in the current month — the API returns counts only for records up to the exact toDate timestamp provided.

Related Endpoints

  • POST /api/Widget/accounts — Retrieve account counts for a given date range and filters
  • POST /api/Widget/transactions — Retrieve transaction summary data for a given date range and filters

Example

curl -X POST https://api.banking.netevia.dev/api/Widget/approved \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "fromDate": "2024-08-01T00:00:00Z",
    "toDate": "2024-10-15T23:59:59Z",
    "agentsId": [101, 102],
    "isoId": 5,
    "profileIds": [201, 202, 203]
  }'
Body Params
date-time
required
date-time
required
agentsId
array of int32s | null
agentsId
int32 | null
profileIds
array of int32s | null
profileIds
Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
string
enum
Defaults to application/json

Generated from available request content types

Allowed:
Response

Language
Credentials
Bearer
JWT
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
text/plain
application/json
text/json