> ## Documentation Index
> Fetch the complete documentation index at: https://deepline.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# The Swarm: Theswarm Get Company Posts

> Get LinkedIn posts for a company identifier. Includes SDK V2 guidance, input constraints, response fields, and Deepline credit cost.

Get LinkedIn posts for a company identifier.

> [!NOTE]
>
> Tool ID: `theswarm_get_company_posts`

## Run this action

Use the TypeScript SDK for one call. Use `ctx.tools.execute(...)` inside a Play for durable calls, scheduled calls, or CSV processing.

```ts theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'theswarm_get_company_posts',
  {
    "linkedinName": "https://www.linkedin.com/in/jane-doe"
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
deepline tools execute theswarm_get_company_posts --input '{
  "linkedinName": "https://www.linkedin.com/in/jane-doe"
}' --json
```

## Example response

The SDK returns this shape at `result.toolResponse.raw`. The example values illustrate the response.

```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
{
  "data": {
    "posts": [
      {
        "urn": "example",
        "actor": {
          "linkedin_url": "https://www.linkedin.com/in/jane-doe",
          "name": "Example",
          "entity_type": "example"
        },
        "post_range": {
          "earliest": "example",
          "latest": "example"
        }
      }
    ]
  }
}
```

Use `deepline describe theswarm_get_company_posts --json` for the latest machine-readable contract.

## Input reference

Fetch LinkedIn posts published by a company

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `payload.linkedinID` | `string` | No | — | LinkedIn company URL slug |
| `payload.linkedinName` | `string` | No | — | LinkedIn company URL slug |
| `payload.perPage` | `integer` | No | — | Number of posts per page Maximum: 100. |
| `payload.page` | `integer` | No | — | Page number (1-based) |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "Fetch LinkedIn posts published by a company",
    "properties": {
      "linkedinID": {
        "type": "string",
        "description": "LinkedIn company URL slug"
      },
      "linkedinName": {
        "type": "string",
        "description": "LinkedIn company URL slug"
      },
      "perPage": {
        "type": "integer",
        "description": "Number of posts per page",
        "maximum": 100
      },
      "page": {
        "type": "integer",
        "description": "Page number (1-based)"
      }
    },
    "required": [],
    "anyOf": [
      {
        "required": [
          "linkedinName"
        ]
      },
      {
        "required": [
          "linkedinID"
        ]
      }
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

Standard tool result payload.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `result.data` | `object` | Yes | — | Provider response payload. |
| `result.data.posts` | `array` | Yes | — | — |
| `result.data.posts[].urn` | `string` | No | — | LinkedIn post URN |
| `result.data.posts[].actor` | `object` | No | — | — |
| `result.data.posts[].actor.linkedin_url` | `string` | No | — | — |
| `result.data.posts[].actor.name` | `string` | No | — | — |
| `result.data.posts[].actor.entity_type` | `string` | No | — | — |
| `result.data.posts[].actor.image` | `string` | No | — | — |
| `result.data.posts[].actor.linkedin_id` | `string` | No | — | — |
| `result.data.posts[].post_range` | `object` | No | — | — |
| `result.data.posts[].post_range.earliest` | `string` | No | — | — |
| `result.data.posts[].post_range.latest` | `string` | No | — | — |
| `result.data.posts[].post_age` | `string` | No | — | — |
| `result.data.posts[].social_activity_counts` | `object` | No | — | — |
| `result.data.posts[].social_activity_counts.comments_count` | `integer` | No | — | — |
| `result.data.posts[].social_activity_counts.shares_count` | `integer` | No | — | — |
| `result.data.posts[].social_activity_counts.reactions_count` | `integer` | No | — | — |
| `result.data.posts[].social_activity_counts.reaction_type_counts` | `array` | No | — | — |
| `result.data.posts[].social_activity_counts.reaction_type_counts[].count` | `integer` | No | — | — |
| `result.data.posts[].social_activity_counts.reaction_type_counts[].reaction_type` | `string` | No | — | — |
| `result.data.posts[].images` | `array` | No | — | — |
| `result.data.posts[].url` | `string` | No | — | — |
| `result.data.posts[].video` | `object` | No | — | — |
| `result.data.posts[].video.url` | `string` | No | — | — |
| `result.data.posts[].video.thumbnail` | `string` | No | — | — |
| `result.data.posts[].reshared_post` | `object \| null` | No | — | Recursive OpenAPI schema reference #/components/schemas/SocialPost. |
| `result.data.posts[].commentary` | `string` | No | — | — |
| `result.data.posts[].header` | `string` | No | — | — |
| `result.data.posts[].header_entity` | `object` | No | — | — |
| `result.data.posts[].header_entity.entity_type` | `string` | No | — | — |
| `result.data.posts[].header_entity.image` | `string` | No | — | — |
| `result.data.posts[].header_entity.linkedin_url` | `string` | No | — | — |
| `result.data.posts[].header_entity.linkedin_id` | `string` | No | — | — |
| `result.data.posts[].header_entity.name` | `string` | No | — | — |
| `result.data.page` | `integer` | No | — | — |
| `result.data.pages` | `integer` | No | — | — |
| `result.data.totalResults` | `integer` | No | — | — |
| `result.meta` | `object` | No | — | Additional response metadata (status, paging). |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "Standard tool result payload.",
    "properties": {
      "data": {
        "type": "object",
        "description": "Provider response payload.",
        "properties": {
          "posts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "urn": {
                  "type": "string",
                  "description": "LinkedIn post URN"
                },
                "actor": {
                  "type": "object",
                  "properties": {
                    "linkedin_url": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "entity_type": {
                      "type": "string"
                    },
                    "image": {
                      "type": "string"
                    },
                    "linkedin_id": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "post_range": {
                  "type": "object",
                  "properties": {
                    "earliest": {
                      "type": "string"
                    },
                    "latest": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "post_age": {
                  "type": "string"
                },
                "social_activity_counts": {
                  "type": "object",
                  "properties": {
                    "comments_count": {
                      "type": "integer"
                    },
                    "shares_count": {
                      "type": "integer"
                    },
                    "reactions_count": {
                      "type": "integer"
                    },
                    "reaction_type_counts": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "count": {
                            "type": "integer"
                          },
                          "reaction_type": {
                            "type": "string"
                          }
                        },
                        "additionalProperties": false
                      }
                    }
                  },
                  "additionalProperties": false
                },
                "images": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "url": {
                  "type": "string"
                },
                "video": {
                  "type": "object",
                  "properties": {
                    "url": {
                      "type": "string"
                    },
                    "thumbnail": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "reshared_post": {
                  "type": [
                    "object",
                    "null"
                  ],
                  "description": "Recursive OpenAPI schema reference #/components/schemas/SocialPost.",
                  "additionalProperties": true
                },
                "commentary": {
                  "type": "string"
                },
                "header": {
                  "type": "string"
                },
                "header_entity": {
                  "type": "object",
                  "properties": {
                    "entity_type": {
                      "type": "string"
                    },
                    "image": {
                      "type": "string"
                    },
                    "linkedin_url": {
                      "type": "string"
                    },
                    "linkedin_id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                }
              },
              "additionalProperties": false
            }
          },
          "page": {
            "type": "integer"
          },
          "pages": {
            "type": "integer"
          },
          "totalResults": {
            "type": "integer"
          }
        },
        "required": [
          "posts"
        ],
        "additionalProperties": false
      },
      "meta": {
        "type": "object",
        "description": "Additional response metadata (status, paging).",
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `fixed` (per call).
* Estimated Deepline credits: `0` per pricing unit.
* Provider-native pricing may still exist outside Deepline credit billing.

## Related documentation

* [The Swarm provider guide](https://deepline.com/docs/providers/theswarm/guide.md)
* [SDK V2 quickstart](https://deepline.com/docs/sdk-v2/quickstart.md)
* [SDK reference](https://deepline.com/docs/sdk-v2/sdk-reference.md)
* [Run tools across a CSV](https://deepline.com/docs/sdk-v2/batch-csv.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.