---
sidebar_position: 3
description: Get lead and other functions to work with Bitrix24 in the Open Integration Package, a free open-source integration library for 1C:Enterprise 8, OneScript and CLI
keywords: [1C, 1С, 1С:Enterprise, 1С:Enterprise 8.3, API, Integration, Services, Exchange, OneScript, CLI, Bitrix24]
---

import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

# Get lead
 Gets a lead by ID



`Function GetLead(Val URL, Val LeadID, Val Token = "") Export`

  | Parameter | CLI option | Type | Required | Description |
  |-|-|-|-|-|
  | URL | --url | String | &#x2714; | URL of webhook or a Bitrix24 domain, when token used |
  | LeadID | --lead | Number, String | &#x2714; | Lead ID |
  | Token | --token | String | &#x2716; | Access token, when app auth method used |

  
  Returns:  Map Of KeyAndValue - serialized JSON of answer from Bitrix24 API

:::tip
Method at API documentation: [crm.lead.get](https://dev.1c-bitrix.ru/rest_help/crm/leads/crm_lead_get.php)
:::
<br/>


```bsl title="1C:Enterprise/OneScript code example"
    URL    = "https://b24-ar17wx.bitrix24.by/rest/1/h0m...";
    LeadID = "2872";

    Result = OPI_Bitrix24.GetLead(URL, LeadID);

    URL    = "b24-ar17wx.bitrix24.by";
    Token  = "6ad03969006e9f06006b12e400000001000...";
    LeadID = "2874";

    Result = OPI_Bitrix24.GetLead(URL, LeadID, Token);
```
 

 <Tabs>
  
    <TabItem value="bash" label="Bash" default>
        ```bash
            oint bitrix24 GetLead \
             --url "b24-ar17wx.bitrix24.by" \
             --lead 2878 \
             --token "***"
        ```
    </TabItem>
  
    <TabItem value="bat" label="CMD/Bat" default>
        ```batch
            oint bitrix24 GetLead ^
             --url "b24-ar17wx.bitrix24.by" ^
             --lead 2878 ^
             --token "***"
        ```
    </TabItem>
</Tabs>


```json title="Result"
{
 "result": {
  "ID": "2878",
  "TITLE": "MegaClient",
  "HONORIFIC": null,
  "NAME": "Ivan",
  "SECOND_NAME": null,
  "LAST_NAME": "Ivanov",
  "COMPANY_TITLE": null,
  "COMPANY_ID": null,
  "CONTACT_ID": "2878",
  "IS_RETURN_CUSTOMER": "N",
  "BIRTHDATE": "",
  "SOURCE_ID": "CALL",
  "SOURCE_DESCRIPTION": null,
  "STATUS_ID": "CONVERTED",
  "STATUS_DESCRIPTION": null,
  "POST": null,
  "COMMENTS": null,
  "CURRENCY_ID": "BYN",
  "OPPORTUNITY": "0.00",
  "IS_MANUAL_OPPORTUNITY": "N",
  "HAS_PHONE": "***",
  "HAS_EMAIL": "Y",
  "HAS_IMOL": "N",
  "ASSIGNED_BY_ID": "1",
  "CREATED_BY_ID": "1",
  "MODIFY_BY_ID": "1",
  "DATE_CREATE": "2025-12-10T20:02:07+00:00",
  "DATE_MODIFY": "2025-12-10T20:02:07+00:00",
  "DATE_CLOSED": "2025-12-09T21:00:00+00:00",
  "STATUS_SEMANTIC_ID": "S",
  "OPENED": "Y",
  "ORIGINATOR_ID": "***",
  "ORIGIN_ID": "***",
  "MOVED_BY_ID": "1",
  "MOVED_TIME": "2025-12-10T20:02:07+00:00",
  "ADDRESS": "Pushkin st., b. 10",
  "ADDRESS_2": null,
  "ADDRESS_CITY": null,
  "ADDRESS_POSTAL_CODE": null,
  "ADDRESS_REGION": null,
  "ADDRESS_PROVINCE": null,
  "ADDRESS_COUNTRY": "Russia",
  "ADDRESS_COUNTRY_CODE": null,
  "ADDRESS_LOC_ADDR_ID": "5758",
  "UTM_SOURCE": null,
  "UTM_MEDIUM": null,
  "UTM_CAMPAIGN": null,
  "UTM_CONTENT": null,
  "UTM_TERM": null,
  "LAST_COMMUNICATION_TIME": null,
  "LAST_ACTIVITY_BY": "1",
  "LAST_ACTIVITY_TIME": "2025-12-10T20:02:07+00:00",
  "EMAIL": [
   {
    "ID": "17258",
    "VALUE_TYPE": "HOME",
    "VALUE": "yo@example.com",
    "TYPE_ID": "EMAIL"
   },
   {
    "ID": "17260",
    "VALUE_TYPE": "WORK",
    "VALUE": "hi@example.com",
    "TYPE_ID": "EMAIL"
   }
  ],
  "PHONE": [
   {
    "ID": "17262",
    "VALUE_TYPE": "WORK",
    "VALUE": "88005553535",
    "TYPE_ID": "PHONE"
   }
  ]
 },
 "time": {
  "start": 1765396932,
  "finish": 1765396932.60248,
  "duration": 0.602480888366699,
  "processing": 0,
  "date_start": "2025-12-10T20:02:12+00:00",
  "date_finish": "2025-12-10T20:02:12+00:00",
  "operating_reset_at": 1765397532,
  "operating": 0
 }
}
```
