Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
@ama-sdk/core
Advanced tools
This package contains a set of plugins, helpers and object definitions to dialog with an API following the ama-sdk
architecture.
Please refer to the ama-sdk-schematics package for getting started with an API based on ama-sdk
.
The API Clients are mandatory to the SDK to indicate the service that should be used by the SDK to process the calls. A list of API Clients are provided by this package:
API Client | Import | Description |
---|---|---|
ApiFetchClient | @ama-sdk/client-fetch | Default API Client based on the browser FetchApi |
ApiBeaconClient | @ama-sdk/core | API Client based on the browser BeaconApi, it is processing synchronous call |
ApiAngularClient | @ama-sdk/core/clients/api-angular-client | API Client using the HttpClient exposed by the @angular/common package |
In order to ease the logging in the ama-sdk plugins, it is possible to connect to third-party logging services.
This can be achieved by adding a Logger
implementation to the options of an API client.
For example, in the Otter showcase application, we could add a ConsoleLogger
(from @o3r/core
) as a parameter to the ApiFetchClient:
const logger = new ConsoleLogger();
function petApiFactory() {
const apiConfig: ApiClient = new ApiFetchClient(
{
basePath: 'https://petstore3.swagger.io/api/v3',
requestPlugins: [new SessionIdRequest()],
fetchPlugins: [],
logger
}
);
return new PetApi(apiConfig);
}
Note: Adding a third-party logging service is optional. If undefined, the fallback is the console logger.
FAQs
Digital API - SDK Core
The npm package @ama-sdk/core receives a total of 10,852 weekly downloads. As such, @ama-sdk/core popularity was classified as popular.
We found that @ama-sdk/core demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.