Skip to main content

Key Exchange

This page is for assignors, originators, investors and distributors: you generate the key pair and send the public key to the QI Tech integration team.

Managers and consultants

Managers and consultants register the public key and receive the API key through the portal itself, without sending keys by email. Follow Portal Integration.

1. Signed request​

All requests to the QI DTVM APIs use HTTPS, with TLS 1.2 or 1.3, and carry two headers:

  1. API-CLIENT-KEY: the API key that identifies your integration, sent by the integration team.
  2. AUTHORIZATION: a JWT signed with your private key, built as in Authentication test.

QI DTVM uses asymmetric keys: the private key signs the requests and the public key lets QI validate the signature. You generate the pair and give QI only the public key.

Attention

The private key is for your company's exclusive use and must be stored securely. QI DTVM will never ask you to share it.

2. Generate the pair​

In a UNIX terminal, generate the EC P-521 private key:

ssh-keygen -t ecdsa -b 521 -m PEM -f private.key

From it, generate the public key:

openssl ec -in private.key -pubout -outform PEM -out public.key.pub

The public key is the public.key.pub file. Only this file is sent to QI. When signing requests with private.key, use the ES512 algorithm, which corresponds to the P-521 curve.

3. Deliver the public key​

Send the public.key.pub file to integracao.dtvm@qitech.com.br and wait for the integration to be configured. The integration team replies with your profile's API key. The API key only works on that profile's host: see Environments (Hosts).

Explanatory video​