Documentation

user.current

Scope: catalog Permissions to execute: for all

List of Bitrix24 user fields to be retrieved as the result of executed method depends on application/webhook scope. Find more details on access to user data in this article.

Get current user information. Method supports [link=919395]secure calling[/link]

Parameters

Method has no parameters.

Call

BX24.callMethod('user.current', {}, function(res){
    alert('Hi, ' + res.data().NAME + '!');
});

Request (xml for clarity of reply)

https://my.bitrix24.com/rest/user.current.xml?auth=7c9d8f00ea0ddd9e02cab3eb2b3bd0d1

Response

<response>
 <result>
  <ID>1</ID>
  <ACTIVE>1</ACTIVE>
  <EMAIL>sigurd@example.com</EMAIL>
  <NAME>Admin</NAME>
  <LAST_NAME>
  <SECOND_NAME>
  <PERSONAL_GENDER>
  <PERSONAL_PROFESSION>
  <PERSONAL_WWW>
  <PERSONAL_BIRTHDAY>1955-04-10T00:00:00+03:00</PERSONAL_BIRTHDAY>
  <PERSONAL_PHOTO>/upload/main/80c/44169_C5_PrimalWaterE500CC.jpg</PERSONAL_PHOTO>
  <PERSONAL_ICQ>
  <PERSONAL_PHONE>
  <PERSONAL_FAX>
  <PERSONAL_MOBILE>
  <PERSONAL_PAGER>
  <PERSONAL_STREET>
  <PERSONAL_CITY>
  <PERSONAL_STATE>
  <PERSONAL_ZIP>
  <PERSONAL_COUNTRY>0</PERSONAL_COUNTRY>
  <WORK_COMPANY>
  <WORK_POSITION>
  <UF_DEPARTMENT>128</UF_DEPARTMENT>
  <UF_INTERESTS>
  <UF_SKILLS>
  <UF_WEB_SITES>
  <UF_XING>
  <UF_LINKEDIN>
  <UF_FACEBOOK>
  <UF_TWITTER>
  <UF_SKYPE>
  <UF_DISTRICT>
  <UF_PHONE_INNER>
 </result>
</response>


© «Bitrix24», 2001-2024