> For the complete documentation index, see [llms.txt](https://help.swarmia.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.swarmia.com/settings/integrations/ai-coding-tool-integrations/custom-ai-tool-integrations/connect-devin-to-swarmia.md).

# Connect Devin to Swarmia

Swarmia detects Devin's pull requests, reviews, and commits automatically. Send Devin usage data to also see adoption and cost.

Swarmia has built-in support for Devin. You don't need to set anything up to track the pull requests, reviews, and commits it creates. You can also send Devin usage data to Swarmia to see adoption and add time-based pull request attribution.

## Track Devin's Git activity

Swarmia detects Devin from its GitHub login and commit emails as soon as it's active in one of your repositories. [Settings → AI tools](https://app.swarmia.com/settings/ai-assistants) shows whether Swarmia has detected it.

Swarmia detects the following activity with high confidence:

* Pull requests opened by Devin, or whose first commit Devin authored, as [cloud agent](/features/ai-tools/ai-tool-detection-and-filters.md#cloud-agent) work
* Pull requests reviewed by Devin, including [Devin Review](https://docs.devin.ai/work-with-devin/devin-review), as [review agent](/features/ai-tools/ai-tool-detection-and-filters.md#review-agent) work
* Commits Devin authored or co-authored as [AI-assisted](/features/ai-tools/ai-tool-detection-and-filters.md#ai-assisted) work

## Send Devin usage data (optional)

{% hint style="info" %}
The built-in Devin integration doesn't fetch usage data yet. To track Devin license usage or token costs, create a custom AI tool for Devin, link its Git identities, and send the usage data to that tool.
{% endhint %}

To show Devin in [AI adoption](/features/ai-tools/ai-adoption.md) and attribute pull requests through recent user activity, retrieve daily per-user consumption data from [Devin's API](https://docs.devin.ai/api-reference/v3/consumption/organizations-consumption-daily-users) and send it to Swarmia's [additional AI integrations API](/settings/integrations/swarmia-apis/additional-ai-integrations.md).

You need the [organization admin](/settings/organization/managing-users-and-roles.md) role to set this up.

1. Go to [Settings → AI tools](https://app.swarmia.com/settings/ai-assistants) and find **Other AI tools**.
2. Click **Add new** and enter **Devin** as the name and `devin` as the API identifier.
3. Under **Linked authors**, select Devin's identities, such as **Devin AI**.
4. Click **Save**.

<figure><img src="https://2772466312-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FMa8uBmGhQgR7MTPq9yh7%2Fuploads%2FrSQqjZghs8bNz58L8ahA%2F005491%402x.png?alt=media&amp;token=5b720b6f-3884-4a92-9bbd-c48c625fe6ed" alt=""><figcaption></figcaption></figure>

When you send the data:

* Match each daily usage record to a Swarmia author by email.
* Report whether the person had access to Devin and whether they used it that day.

Swarmia uses these daily records for [time-based, low-confidence AI-assisted attribution](/features/ai-tools/ai-tool-detection-and-filters.md#ai-assisted). A pull request counts as AI-assisted when its commit author used Devin within the previous 24 hours. Use the [high-confidence-only filter](/features/ai-tools/ai-tool-detection-and-filters.md#ai-assisted-high-confidence-only) to exclude this time-based attribution.

For authentication, request fields, and data-import details, see [send usage data to the API](/settings/integrations/ai-coding-tool-integrations/custom-ai-tool-integrations.md#send-usage-data-to-api).

### Include Devin cost (optional)

Devin's API reports usage in Agent Compute Units (ACUs), Cognition's billing meter for Devin. If you know the USD price of an ACU for your plan, convert each user's ACUs to USD and include the cost in the usage data you send to Swarmia.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.swarmia.com/settings/integrations/ai-coding-tool-integrations/custom-ai-tool-integrations/connect-devin-to-swarmia.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
