TuCloudAPI authrequest: Difference between revisions
TuCloudAPI reference regenerated from func=help: tenancy rule, pbx notes on every PBX-scoped function, error codes |
TuCloudAPI reference (generated from func=help; ringinuse 2026-10-31) |
||
| (One intermediate revision by the same user not shown) | |||
| Line 2: | Line 2: | ||
== Description == | == Description == | ||
Ask for a magic-link e-mail. PUBLIC: needs no ukey and no session, because neither exists yet. Relayed to magiclogin, whose answer is passed through unchanged -- including the fake session code it returns for an address that does not exist, so the form cannot be used to discover which e-mails are registered. | Ask for a magic-link e-mail. PUBLIC: needs no ukey and no session, because neither exists yet. Relayed to magiclogin, whose answer is passed through unchanged -- including the fake session code it returns for an address that does not exist, so the form cannot be used to discover which e-mails are registered. login_code is the 3-digit code the user must see on the screen where they asked for the link and compare with the one on the link page before authorizing; it is a STRING with its leading zeros ("003"), never a number. The optional captcha is the solved authchallenge payload: verified whenever it is sent, required only when the service runs with captcha_required (then captcha_required / captcha_invalid). | ||
== Call == | == Call == | ||
| Line 13: | Line 13: | ||
|- | |- | ||
| <code>email</code> || string || Yes || — || The e-mail to send the link to. | | <code>email</code> || string || Yes || — || The e-mail to send the link to. | ||
|- | |||
| <code>captcha</code> || string || No || — || base64 of the solved authchallenge JSON {algorithm, challenge, number, salt, signature}. | |||
|} | |} | ||
== Example == | == Example == | ||
| Line 18: | Line 20: | ||
== Response == | == Response == | ||
{ok, status, session_code, expires_in}. | {ok, status, session_code, login_code, expires_in}. Show login_code as-is; poll session_code with authpoll. | ||
---- | ---- | ||
Back to [[TuCloudAPI]] | Back to [[TuCloudAPI]] | ||
[[Category:TuCloudAPI SuperRoot]][[Category:TuCloudAPI Operator]][[Category:TuCloudAPI Client]][[Category:TuCloudAPI]] | [[Category:TuCloudAPI SuperRoot]][[Category:TuCloudAPI Operator]][[Category:TuCloudAPI Client]][[Category:TuCloudAPI]] | ||
Latest revision as of 11:47, 31 October 2026
TuCloudAPI function to manage FuturePBX (the cloud PBX). Available to: SuperRoot, Operator, Client.
Description
Ask for a magic-link e-mail. PUBLIC: needs no ukey and no session, because neither exists yet. Relayed to magiclogin, whose answer is passed through unchanged -- including the fake session code it returns for an address that does not exist, so the form cannot be used to discover which e-mails are registered. login_code is the 3-digit code the user must see on the screen where they asked for the link and compare with the one on the link page before authorizing; it is a STRING with its leading zeros ("003"), never a number. The optional captcha is the solved authchallenge payload: verified whenever it is sent, required only when the service runs with captcha_required (then captcha_required / captcha_invalid).
Call
https://tucloudapi.7kas.com:9087/tucloud?func=authrequest&ukey=YOUR_KEY
GET, or POST with the parameters form-urlencoded in the body. Requires the ukey parameter.
Parameters
| Parameter | Type | Required | Default | Meaning |
|---|---|---|---|---|
email |
string | Yes | — | The e-mail to send the link to. |
captcha |
string | No | — | base64 of the solved authchallenge JSON {algorithm, challenge, number, salt, signature}. |
Example
https://tucloudapi.7kas.com:9087/tucloud?func=authrequest&email=alguien@example.com
Response
{ok, status, session_code, login_code, expires_in}. Show login_code as-is; poll session_code with authpoll.
Back to TuCloudAPI