---
sidebar_position: 5
description: Get posts 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 posts
 Gen post or array of post with ID or rights selection



`Function GetPosts(Val URL, Val PostID = "", Val Filter = "UA", Val Token = "") Export`

  | Parameter | CLI option | Type | Required | Description |
  |-|-|-|-|-|
  | URL | --url | String | &#x2714; | URL of webhook or a Bitrix24 domain, when token used |
  | PostID | --postid | String, Number | &#x2716; | Id of important post |
  | Filter | --sel | String | &#x2716; | Post selection by rights: UA all, SGn work group, Un user, DRn depart, Gn group |
  | 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: [log.blogpost.get](https://dev.1c-bitrix.ru/rest_help/log/log_blogpost_get.php)
:::
<br/>


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

    Result = OPI_Bitrix24.GetPosts(URL, PostID);

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

    Result = OPI_Bitrix24.GetPosts(URL, PostID, , Token);
```
 

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


```json title="Result"
{
 "result": [
  {
   "ID": "3456",
   "BLOG_ID": "1",
   "PUBLISH_STATUS": "P",
   "TITLE": "New post title",
   "AUTHOR_ID": "1",
   "ENABLE_COMMENTS": "Y",
   "NUM_COMMENTS": "0",
   "CODE": null,
   "MICRO": "N",
   "DETAIL_TEXT": "New post text",
   "DATE_PUBLISH": "2025-12-10T19:48:04+00:00",
   "CATEGORY_ID": null,
   "HAS_SOCNET_ALL": "N",
   "HAS_TAGS": "N",
   "HAS_IMAGES": "N",
   "HAS_PROPS": "Y",
   "HAS_COMMENT_IMAGES": null,
   "UF_BLOG_POST_DOC": {
    "ID": "1",
    "ENTITY_ID": "BLOG_POST",
    "FIELD_NAME": "UF_BLOG_POST_DOC",
    "USER_TYPE_ID": "file",
    "XML_ID": "UF_BLOG_POST_DOC",
    "SORT": "100",
    "MULTIPLE": "Y",
    "MANDATORY": "N",
    "SHOW_FILTER": "N",
    "SHOW_IN_LIST": "N",
    "EDIT_IN_LIST": "Y",
    "IS_SEARCHABLE": "Y",
    "SETTINGS": {
     "SIZE": 20,
     "LIST_WIDTH": "***",
     "LIST_HEIGHT": 0,
     "MAX_SHOW_SIZE": 0,
     "MAX_ALLOWED_SIZE": 0,
     "EXTENSIONS": [],
     "TARGET_BLANK": "Y",
     "DEFAULT_VIEW": null
    },
    "EDIT_FORM_LABEL": null,
    "LIST_COLUMN_LABEL": null,
    "LIST_FILTER_LABEL": null,
    "ERROR_MESSAGE": null,
    "HELP_MESSAGE": null,
    "USER_TYPE": {
     "USER_TYPE_ID": "file",
     "CLASS_NAME": "Bitrix\\Main\\UserField\\Types\\FileType",
     "EDIT_CALLBACK": [
      "***",
      "***"
     ],
     "VIEW_CALLBACK": [
      "***",
      "***"
     ],
     "USE_FIELD_COMPONENT": true,
     "DESCRIPTION": "Файл",
     "BASE_TYPE": "file"
    },
    "VALUE": false,
    "ENTITY_VALUE_ID": 3456,
    "VALUE_EXISTS": true,
    "VALUE_RAW": null,
    "CUSTOM_DATA": []
   },
   "UF_BLOG_POST_URL_PRV": {
    "ID": "5",
    "ENTITY_ID": "BLOG_POST",
    "FIELD_NAME": "UF_BLOG_POST_URL_PRV",
    "USER_TYPE_ID": "url_preview",
    "XML_ID": "UF_BLOG_POST_URL_PRV",
    "SORT": "100",
    "MULTIPLE": "N",
    "MANDATORY": "N",
    "SHOW_FILTER": "N",
    "SHOW_IN_LIST": "N",
    "EDIT_IN_LIST": "Y",
    "IS_SEARCHABLE": "Y",
    "SETTINGS": [],
    "EDIT_FORM_LABEL": null,
    "LIST_COLUMN_LABEL": null,
    "LIST_FILTER_LABEL": null,
    "ERROR_MESSAGE": null,
    "HELP_MESSAGE": null,
    "USER_TYPE": {
     "USER_TYPE_ID": "url_preview",
     "CLASS_NAME": "Bitrix\\Main\\UrlPreview\\UrlPreviewUserType",
     "DESCRIPTION": "Содержимое ссылки",
     "BASE_TYPE": "int"
    },
    "VALUE": null,
    "ENTITY_VALUE_ID": 3456,
    "VALUE_EXISTS": true,
    "VALUE_RAW": null,
    "CUSTOM_DATA": []
   },
   "UF_GRATITUDE": {
    "ID": "9",
    "ENTITY_ID": "BLOG_POST",
    "FIELD_NAME": "UF_GRATITUDE",
    "USER_TYPE_ID": "integer",
    "XML_ID": "UF_GRATITUDE",
    "SORT": "100",
    "MULTIPLE": "N",
    "MANDATORY": "N",
    "SHOW_FILTER": "N",
    "SHOW_IN_LIST": "N",
    "EDIT_IN_LIST": "Y",
    "IS_SEARCHABLE": "N",
    "SETTINGS": {
     "SIZE": 20,
     "MIN_VALUE": 0,
     "MAX_VALUE": 0,
     "DEFAULT_VALUE": null
    },
    "EDIT_FORM_LABEL": null,
    "LIST_COLUMN_LABEL": null,
    "LIST_FILTER_LABEL": null,
    "ERROR_MESSAGE": null,
    "HELP_MESSAGE": null,
    "USER_TYPE": {
     "USER_TYPE_ID": "integer",
     "CLASS_NAME": "Bitrix\\Main\\UserField\\Types\\IntegerType",
     "EDIT_CALLBACK": [
      "***",
      "***"
     ],
     "VIEW_CALLBACK": [
      "***",
      "***"
     ],
     "USE_FIELD_COMPONENT": true,
     "DESCRIPTION": "Целое число",
     "BASE_TYPE": "int"
    },
    "VALUE": null,
    "ENTITY_VALUE_ID": 3456,
    "VALUE_EXISTS": true,
    "VALUE_RAW": null,
    "CUSTOM_DATA": []
   },
   "UF_BLOG_POST_FILE": {
    "ID": "19",
    "ENTITY_ID": "BLOG_POST",
    "FIELD_NAME": "UF_BLOG_POST_FILE",
    "USER_TYPE_ID": "disk_file",
...
```
