phpVMS includes a REST API that can be used for retrieving or saving information.
Where indicated, pagination is enabled/available. When calling those APIs, the data is returned in this format:
datacontains a list of all of the objects (for example, the airports)
linkscontains the links to navigate through the paginated list
metacontains information about the current dataset
Laravel's API Middleware includes a rate limiter, which, by default, it set to 60 requests per minute, per-IP.
If you exceed the throttling, you'll have a
429 Too Many Requests HTTP response code. You'll also have a
Retry-After header included, indicating the number of seconds to wait:
The below headers will also be included.
When a request is made, several headers are returned to show you where you are in terms of throttling:
To read some more information about how the throttling works in Laravel, check out this page
Where possible, the standard HTTP error codes are followed and returned, with extra information in the body, if available.
401 is returned if the API key is invalid, or the user is disallowed from API access. The
message parameter will offer more error.
404 is returned if an entity is not found
400, with details in the
message parameter about the bad input.