1.0.1 • Published 3 years ago

@antavo/api-async-client-node v1.0.1

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

Antavo API Client

Antavo API Client helps you send secure HTTP requests asynchronously (for APIs).

Usage

  1. Get the Client class in order to initialize it later:

    var Client = require("@antavo/api-async-client-node").Client
  2. Create a new client object like:

    var client = new Client(ENVIRONMENT, API_KEY, API_SECRET)

Requests

  • GET

    client.get(URI, PARAMS).then().catch()
  • POST

    client.post(URI, DATA_OBJECT).then().catch()

Responses

KeyTypeDescription
statusCodeIntegerHTTP status code of the request
headersObject<String, mixed>HTTP response headers
bodyBufferResponse body in raw format. Convert it through getBody('utf8').
urlStringRequest URL