3.1.0 • Published 1 year ago

synchronizers v3.1.0

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

TypeScript Client for Synchronizers API

This client allows you to make requests to various endpoints of the API using TypeScript. It uses types defined in the types.ts file to ensure that data is correct.

Below is a list of available endpoints and their documentation:

List events

This endpoint allows you to retrieve a paginated list of events registered in the application.

Endpoint

GET /api/v1/events

Base variables

NameTypeDescription
baseUrlstringThe base URL of the API.

Parameters

NameTypeDescriptionOptional
limitnumberThe maximum number of items to return on a page.Yes
pagenumberThe page number to return. The first page is 1.Yes
sortSortThe order in which to return the items. It can be "asc" for ascending order or "desc" for descending order.Yes

Sort is a type defined as "asc" | "desc".

Response

The response contains a list of events and related meta-information.

export  type ListEventsResponse = {
	data: Event[];
	meta: {
	cronjob: Cronjob;
	pagination: Pagination;
};

Where Event, Cronjob, and Pagination are types defined in types.ts. Please refer to the type documentation for more information.

Example usage

GET https://example.com/api/v1/events?limit=10&page=2&sort=desc Returns a response that contains a paginated list of events, where 10 items have been returned from page 2, ordered in descending order.

3.1.0

1 year ago

3.0.0

1 year ago

2.3.0

1 year ago