Invite a user to log in
Auth: Authorization: Bearer nsin_… or X-Api-Key: nsin_… — see API keys.
Sends the user a link to choose a password and sign in to the NSIN panel, by email or by SMS (Iranian mobiles only) to the contact you stored. The link works for 7 days and only for that contact; editing the contact cancels it. Accepting writes the contact onto the account as verified.
At most one invite per user every 10 minutes, and 50 invites a day in all; changing a user's contact does not reset either. The default channel is email when the user has one, else SMS.
Path parameters
- idintegerrequiredpath
The id of one of your users.
Request body
Content type: application/json
- channelstringOne of:
"email""sms"
Responses
200Sent. The user, with invited_at set.
Content type: application/json
- idinteger
- labelstring
- namestring | null
- contact_emailstring
- contact_phonestring
- invited_atstring | null (date-time)
When the last login invite was sent.
- login_acceptedboolean
The person accepted an invite and has their own login.
- billing_modestringOne of:
"reseller""self" - balance_rialsinteger (int64)
The user's own wallet.
- domainsinteger
- suspended_domainsinteger
Domains you suspended.
- created_atstring (date-time)
{
"id": 0,
"label": "string",
"name": "string",
"contact_email": "string",
"contact_phone": "string",
"invited_at": "2026-01-01T00:00:00Z",
"login_accepted": true,
"billing_mode": "reseller",
"balance_rials": 0,
"domains": 0,
"suspended_domains": 0,
"created_at": "2026-01-01T00:00:00Z"
}400No email or phone for the channel, or SMS to a number that isn't an Iranian mobile.
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "read-only API key"
}401Missing, malformed, revoked or expired API key. (A valid key whose
account has been deactivated gets 403 account is inactive instead.)
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "invalid API key"
}403The key is read-only and this endpoint is a write. Read-only keys may
only issue GET, HEAD and OPTIONS.
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "read-only API key"
}404No user with this id among yours.
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "user not found"
}409The user already has their own login.
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "read-only API key"
}429An invite went out a few minutes ago, or you reached the daily limit.
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "read-only API key"
}Example request
curl -X POST "https://api.nsin.ir/reseller/v1/users/0/invite" \
-H "Authorization: Bearer $NSIN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"channel": "email"
}'