Set a mobile phone

POST /api/2.0/authentication/setphone

Request

Sets a mobile phone for the current user.

Headers

Acceptenum of string

Can be one of: application/json, text/json, text/plain.

Content-Typeenum of string

Can be one of: application/json, application/*+json, text/json.

Body

Mobile phone request parameters

mobilePhonestring

Mobile phone

Examples

POST /api/2.0/authentication/setphone HTTP/1.1
Accept: application/json
Content-Length: 32
Content-Type: application/json
Host: example.com

{
  "mobilePhone": "some text"
}
curl --request POST \
  --url https://example.com/api/2.0/authentication/setphone \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data '{
  "mobilePhone": "some text"
}'

Responses

200

Authentication data

tokenstring

Authentication token

expiresstringformat: date-time

Token expiration time

smsboolean

Specifies if the authentication code is sent by SMS or not

phoneNoisestring

Phone number

tfaboolean

Specifies if the two-factor application is used or not

tfaKeystring

Two-factor authentication key

confirmUrlstringformat: uri

Confirmation email URL

Get Help

  • If you have any questions about ONLYOFFICE DocSpace, try the FAQ section first.
  • You can request a feature or report a bug by posting an issue on GitHub.
  • You can also ask our developers on ONLYOFFICE forum (registration required).