Getting Started Guide
TNID API — Getting Started
0) What you’ll use
Auth endpoints:
/auth/create_user_otp
,/auth/token
GraphQL endpoints:
/user
(for people) and/company
(for businesses)You can try everything with Postman first. docs.tnid.com+1
1) Create (or claim) your individual profile
Think of this as “getting your user login.”
Step A — Request a one-time code (OTP)
Send your phone number (and, if you’re creating a new user, first/last name + email) to /auth/create_user_otp
. You’ll receive an OTP. docs.tnid.com
Step B — Exchange the OTP for a Bearer token
Send your telephone_number
and otp_code
to /auth/token
.
You’ll get an access_token
(Bearer token) that lets you call the /user
GraphQL API. Save it securely. docs.tnid.com
Optional — Update your user profile
With your user token, call the /user
GraphQL mutation updateUser
to set things like firstName
, lastName
, username
, or aboutMe
. docs.tnid.com
Tip: If you prefer a point-and-click test, open Postman → choose GraphQL → paste your token into the Authorization: Bearer header → target
/user
. docs.tnid.com
2) Create your company (as that user)
Once you have a user token, you can make a company and (optionally) mint credentials for it.
Step A — Create the company profile
Call the createCompany
mutation on /user
and provide basics (legalName
, profileName
, optional brandName
, taxId
, etc.).
If you include provisionCompanyClientSecret: true
, TNID will also return a clientId
/clientSecret
you can use for company-level API calls. docs.tnid.com
Step B — (Alternative) Generate company credentials later
If you didn’t provision in step A, you can still create client credentials from the TNID UI (Client Secrets) and then exchange client_id
/client_secret
at /auth/token
to get a company Bearer token. Use that token with /company
GraphQL. docs.tnid.com
Optional — Update your company profile
Use the updateCompany
mutation to adjust legalName
, brandName
, yearFounded
, aboutUs
, etc. (with your company token). docs.tnid.com
3) Common “first calls” after setup
Find companies (to connect with or avoid duplicates)
Query companies
(name, taxId, email, telephoneNumber, webpage) via /company
. Handy when checking if your org already exists. docs.tnid.com
Invite another company or request a B2B connection
Invite by details (e.g., legal name + a rep’s email) using
createB2bInvite
. docs.tnid.comOr send a connection request by
invitedCompanyId
withcreateB2bConnectionRequest
. docs.tnid.com
Search for people / see your consumer connections
Use searchPeople
and b2cConnections
on /company
. docs.tnid.com+1
User-side spam reporting (popular early integration)
As a user, call createSpamReport
/ listSpamReports
on /user
to help your customers report unwanted communications. docs.tnid.com+1
4) Where to point your requests
GraphQL
People:
/user
Companies:
/company
docs.tnid.com
Auth
OTP:
/auth/create_user_otp
Token exchange:
/auth/token
docs.tnid.com+1
Postman quick start (browse schema + run mutations with your Bearer token). docs.tnid.com
5) Quick mental model
Become a user (OTP → token →
/user
).Create your company (as that user) and mint company creds.
Act as the company (company token →
/company
) for B2B/B2C, profile updates, invites, etc. docs.tnid.com+1
Last updated
Was this helpful?