Spotify Connector Shows "Active" in UI but Returns Empty via API v2

Hi Replit team,

I’m having an issue with the Spotify Connector where it appears connected in the UI but isn’t accessible programmatically.

Setup:

  • Spotify connector shows as “Active” in the Integrations panel (https://replit.com/integrations)

  • Using the official blueprint code from the Spotify integration documentation

  • Node.js app with @spotify/web-api-ts-sdk v7.0.0

Problem:
When querying the Connectors API programmatically, it returns empty results:

const hostname = process.env.REPLIT_CONNECTORS_HOSTNAME;

const xReplitToken = process.env.REPL_IDENTITY

? 'repl ' + process.env.REPL_IDENTITY

: process.env.WEB_REPL_RENEWAL

? 'depl ' + process.env.WEB_REPL_RENEWAL

: null;

// Both queries return empty items array

const allConnections = await fetch(

'https://' + hostname + '/api/v2/connection?include_secrets=true',

{

headers: {

'Accept': 'application/json',

'X_REPLIT_TOKEN': xReplitToken

}

}

).then(res => res.json());

// Returns: { items: [], total: 0, limit: 50, offset: 0, has_next_page: false }

const spotifyConnection = await fetch(

'https://' + hostname + '/api/v2/connection?include_secrets=true&connector_names=spotify',

{ /* same headers */ }

).then(res => res.json());

// Also returns: { items: [], total: 0, ... }

Environment:

  • REPLIT_CONNECTORS_HOSTNAME = connectors.replit.com :white_check_mark:

  • REPL_IDENTITY is set :white_check_mark:

  • Spotify shows “Active” with green dot in UI :white_check_mark:

What I’ve Tried:

  1. Disconnected and reconnected the Spotify integration

  2. Restarted the application multiple times

  3. Verified environment variables are set correctly

  4. Used exact blueprint code from integration documentation

Questions:

  1. Is there a delay between connecting an integration in the UI and it being available via API?

  2. Is the connector perhaps linked at the user level but not the app level?

  3. Are there any additional steps needed to make a connected integration accessible programmatically?

The integration appears to be working at the UI level but not accessible through the standard API approach. Any guidance would be appreciated!