1.3.0 • Published 12 months ago
@drupal-api-client/api-client v1.3.0
api-client
This package contains the base class for the Drupal API Client. For more information, see https://www.drupal.org/project/api_client for more information about this project.
Installation
npm install @drupal-api-client/api-clientUsage
The ApiClient is a base class meant to be extended.
The base class includes the following parameters:
BaseUrl: The url to use for all API requestsapiPrefix: The base path for the JSON:API endpointcache: An optional caching interfacecustomFetch: An optional method to use in place of the defaultfetchmethodauthentication: Optional credentials for authenticated requestsdefaultLocale: An optional locale to use for requests by default.
For an example of an extended ApiClient, see JsonApiClient