Getting started

Make your first call with a test key. It takes about five minutes and no real cover is issued.

Before you startlink

You need:

  • A merchant dashboard account with a business. Set up your business walks through it.
  • A test API key (sk_test_...), created on the merchant dashboard under API Keys.

1. Authenticatelink

Send your key in the x-api-key header, as <keyId>:<secret>:

x-api-key: sk_test_REPLACE_ME:<secret>

A missing, unknown, inactive or wrong key is 401. The key id prefix picks the environment: sk_test_ for test, sk_live_ for live.

2. Make your first calllink

List the product types the platform files products under:

export INSURETECH_API_KEY='sk_test_...:...'

curl https://insure-api.netapps.ng/api/v1/taxonomy \
  -H "x-api-key: $INSURETECH_API_KEY"

Then list the products your business may sell:

curl "https://insure-api.netapps.ng/api/v1/products?limit=5" \
  -H "x-api-key: $INSURETECH_API_KEY"

An empty items list means no product is available to your business in this environment yet. Ask NetApps InsureTech support which product types your business is set up for.

3. Check the headerslink

Every response carries:

HeaderUse it for
X-Request-IdQuoting a call to support. Send your own, such as your order number, and it is echoed back.
X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-ResetPacing your calls. Over the budget you get 429 with Retry-After.

4. Send a writelink

Every write takes an Idempotency-Key: a UUIDv4 you generate for that one request. Send the same key again after a network error and the write still happens once.

curl -X POST https://insure-api.netapps.ng/api/v1/quotes \
  -H "x-api-key: $INSURETECH_API_KEY" \
  -H "Idempotency-Key: $(uuidgen | tr 'A-Z' 'a-z')" \
  -H "Content-Type: application/json" \
  -d @quote.json

Price a quote shows what goes in quote.json.

Use Postmanlink

You can import this API into Postman instead:

  1. Choose Import and paste https://insure-api.netapps.ng/api/v1/openapi.json.
  2. Under View Import Settings, set Folder organization to Tags, Parameter generation to Example, and turn Enable optional parameters off.
  3. Create an environment with baseUrl set to https://insure-api.netapps.ng/api/v1 and apiKey set to your key as a secret variable.
  4. On every write, replace the example Idempotency-Key with {{$guid}}, so Postman sends a fresh UUID each time.

Next stepslink