<@U04S8PLJWMT> I have a self hosted airbyte instan...
# ask-ai
w
@kapa.ai I have a self hosted airbyte instance but I am struggling to get a bearer token back
k
To obtain a bearer token for your self-hosted Airbyte instance, you need to follow these steps: 1. Create an Application in the Airbyte UI - Log into your Airbyte UI. - Go to Settings → Account → Applications. - Click "Create an application" and give it a name. - You will receive a
client_id
and
client_secret
(the secret can be revealed by clicking the icon next to it) [Configuring API Access](https://docs.airbyte.com/platform/using-airbyte/configuring-api-access). 2. Obtain an Access Token - Make a POST request to your Airbyte instance:
Copy code
POST <YOUR_WEBAPP_URL>/api/v1/applications/token
- The request body should be:
Copy code
json      {        "client_id": "<your_client_id>",        "client_secret": "<your_client_secret>"      }
- Replace
<YOUR_WEBAPP_URL>
with the URL you use to access your Airbyte UI (e.g., `http://localhost:8000`). 3. Receive the Bearer Token - The response will include an
access_token
(bearer token) that you can use to authenticate API requests. Note that this token is short-lived (typically 3 minutes), so you may need to fetch a new one before each request [Configuring API Access](https://docs.airbyte.com/platform/using-airbyte/configuring-api-access). Example cURL command:
Copy code
bash curl -X POST http://localhost:8000/api/v1/applications/token \   -H "Content-Type: application/json" \   -d '{"client_id": "YOUR_CLIENT_ID", "client_secret": "YOUR_CLIENT_SECRET"}'
If you follow these steps and still do not receive a token, double-check that your Airbyte instance is running and accessible, and that your credentials are correct. If you encounter a specific error message, please provide it for more targeted troubleshooting. For more details, see the official documentation: [Configuring API Access](https://docs.airbyte.com/platform/using-airbyte/configuring-api-access).