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

# Route Agent Package Installs Through JFrog

> Make agents install npm, PyPI, and other packages from your JFrog Artifactory instead of public registries, using an access token they never see.

## Overview

Buckle routes your agents' package installs through your own [JFrog Artifactory](https://jfrog.com/artifactory/), using an access token. Agents pull npm, PyPI, and other packages from your approved remote repositories, and the gateway injects the token so your agent never sees it.

Connecting takes about a minute.

## What you will set up

* A JFrog access token with read and deploy on your remote repositories
* A connection that routes agent package installs through your Artifactory
* Default blocks on the public npm registry and PyPI

## Connect JFrog Artifactory

**1. Create an access token in JFrog**

In the JFrog Platform, open **Administration** > **User Management** > **Access Tokens** and click **Generate Token**. Give it **read and deploy** on the remote repositories agents should use, and copy it right away.

**2. Enter it in Buckle**

In the Buckle dashboard, open **Settings** > **Apps** > **JFrog Artifactory** and fill in:

* **Access Token:** the token you copied.
* **JFrog Host:** your host, for example `mycompany.jfrog.io`.

Click **Connect JFrog Artifactory**.

![Buckle connect window for JFrog Artifactory, showing the setup guide link, the Access Token and JFrog Host fields, and the Connect JFrog Artifactory button.](https://mintcdn.com/onecli-17d3f772/h1DTAVlDkLshz4JZ/images/integrations/jfrog-artifactory/buckle-connect-jfrog-artifactory.png?fit=max\&auto=format\&n=h1DTAVlDkLshz4JZ\&q=85\&s=dcabb375f1b4d6f021fc124783450c60)

The JFrog Artifactory connect window in Buckle.

> [!NOTE]
>
> Buckle doesn't test the token when you connect. A wrong token or host shows up on the agent's first package install.

## What it changes for agents

When JFrog is connected, Buckle blocks the public npm registry (`registry.npmjs.org`) and PyPI (`pypi.org`) by default, so installs go through your Artifactory. You can change these blocks under **Settings** > **Apps** > **JFrog Artifactory**.

## Controlling access

[Grant](/docs/guides/agent-access.md) the connection to each agent that needs it. Organization [rules](/docs/guides/rules.md) add guardrails on top. A blocked request never reaches JFrog.

To disconnect, remove the connection in **Settings** > **Apps** > **JFrog Artifactory**, then revoke the token in JFrog under **Access Tokens**.

## FAQ

> [accordion] How do I rotate the JFrog access token?
>
> Generate a new token in JFrog, then update it in **Settings** > **Apps** > **JFrog Artifactory**. Agents pick up the new token automatically. Then revoke the old token.

> [accordion] How do I keep the token out of the agent's context?
>
> Don't put it in `.npmrc` or `pip.conf` in the agent's environment. Store it in Buckle, and the gateway injects it at the proxy. See [How it works](/docs/how-it-works.md).

> [accordion] Why did the agent's first install fail?
>
> Buckle doesn't test the token when you connect, so a wrong token or host shows up on the first package install. Check both in the connection.

> [accordion] Can agents still reach public npm or PyPI?
>
> Not by default. Buckle blocks `registry.npmjs.org` and `pypi.org` when JFrog is connected. You can change these blocks in the connection settings.


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