Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions src/apify-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,17 @@ export function getApifyAPIBaseUrl(): string {

export class ApifyClient extends _ApifyClient {
constructor(options: ApifyClientOptions) {
/**
* In order to publish to DockerHub, we need to run their build task to validate our MCP server.
* This was failing since we were sending this dummy token to Apify in order to build the Actor tools.
* So if we encounter this dummy value, we remove it to use Apify client as unauthenticated, which is sufficient
* for server start and listing of tools.
*/
if (options.token?.toLowerCase() === 'your-apify-token') {
// eslint-disable-next-line no-param-reassign
delete options.token;
}

super({
...options,
baseUrl: getApifyAPIBaseUrl(),
Expand Down