### Install Nango with Docker Compose Source: https://nango.dev/docs/guides/platform/self-hosting Download the docker-compose.yaml file and start Nango services in detached mode. ```bash mkdir nango && cd nango wget https://raw.githubusercontent.com/NangoHQ/nango/master/docker-compose.yaml docker-compose up -d ``` -------------------------------- ### Install Local Builder Skill Source: https://nango.dev/docs/implementation-guides/platform/functions/customize-template Install the local builder skill to get additional context and assistance while building Nango functions locally. ```bash npx skills add NangoHQ/skills -s building-nango-functions-locally ``` -------------------------------- ### Initialize Slack MCP Connection with Node.js SDK Source: https://nango.dev/docs/api-integrations/slack-mcp This Node.js example demonstrates how to initialize a connection to the Slack MCP server using the Nango backend SDK. Install the SDK with `npm i @nangohq/node`. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.post({ endpoint: '/v2/mcp', providerConfigKey: '', connectionId: '', body: { jsonrpc: '2.0', id: 1, method: 'initialize', params: { protocolVersion: '2025-06-18', capabilities: {}, clientInfo: { name: 'nango-client', version: '1.0.0' } } } }); console.log(res.data); ``` -------------------------------- ### Fetch Locations using Node.js SDK Source: https://nango.dev/docs/integrations/all/greenhouse-onboarding This example shows how to fetch a list of locations from the Greenhouse Onboarding API using Nango's Node.js SDK. Ensure you have installed the SDK using `npm i @nangohq/node`. ```APIDOC ## Fetch Locations using Node.js SDK ### Description This Node.js code snippet demonstrates how to use the Nango SDK to fetch a list of locations from the Greenhouse Onboarding API. ### Installation ```bash npm install @nangohq/node ``` ### Code Example ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.post({ endpoint: '/graphql', providerConfigKey: '', connectionId: '', data: { query: `query { locations(first: 10) { pageInfo { hasNextPage endCursor } edges { node { id name address externalId } } } }` } }); console.log(JSON.stringify(res.data, null, 2)); ``` ### Parameters - **secretKey** (string) - Your Nango secret key. - **providerConfigKey** (string) - Your Greenhouse integration ID. - **connectionId** (string) - The specific connection ID for Greenhouse. - **data.query** (string) - The GraphQL query to fetch locations. ### Response Example (Success) ```json { "locations": { "pageInfo": { "hasNextPage": false, "endCursor": "cursor-string" }, "edges": [ { "node": { "id": "location-id", "name": "Location Name", "address": "123 Main St", "externalId": "ext-123" } } ] } } ``` ``` -------------------------------- ### Install Nango Node.js SDK Source: https://nango.dev/docs/reference/sdks/node Install the Nango Node.js SDK using npm. ```bash npm i -S @nangohq/node ``` -------------------------------- ### Fetch Clients using Node.js SDK Source: https://nango.dev/docs/integrations/all/passportal This Node.js example demonstrates how to use the Nango SDK to fetch a list of clients from the Passportal API. Install the SDK using 'npm i @nangohq/node' and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); // Fetch a list of clients from Passportal const res = await nango.get({ endpoint: '/api/v2/clients', providerConfigKey: '', connectionId: '' }); console.log(res.data); ``` -------------------------------- ### Call PingOne API with Node.js SDK Source: https://nango.dev/docs/integrations/all/pingone-cc This Node.js example demonstrates how to fetch a list of environments from the PingOne API using Nango's backend SDK. Install the SDK with `npm i @nangohq/node` and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ // https://apidocs.pingidentity.com/pingone/platform/v1/api/#get-read-all-environments endpoint: '/v1/environments', providerConfigKey: '', params: { limit: 10 }, connectionId: '' }); console.log(res.data); ``` -------------------------------- ### Call Quipteams API using Node.js SDK Source: https://nango.dev/docs/api-integrations/quipteams This Node.js example demonstrates how to use the Nango SDK to fetch data from the Quipteams API. Install the SDK using 'npm i @nangohq/node' and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/api/v1/quotes', providerConfigKey: '', connectionId: '' }); console.log(res.data); ``` -------------------------------- ### Fetch Builder.io Content via Node.js SDK Source: https://nango.dev/docs/api-integrations/builder-io-public This Node.js example demonstrates how to use the Nango backend SDK to fetch data from the Builder.io Content API. Install the SDK using 'npm i @nangohq/node' and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/api/v3/content/my-model-name', providerConfigKey: '', connectionId: '' }); console.log(res.data); ``` -------------------------------- ### Example Response for Create Sync Variant Source: https://nango.dev/docs/reference/sdks/node An example of the response received after successfully creating a sync variant. ```json { "id": "12345", "name": "SYNC_NAME", "variant": "VARIANT_NAME" } ``` -------------------------------- ### Get Script Configuration Source: https://nango.dev/docs/reference/sdks/node Fetches script configuration for a given service. You can optionally specify 'nango' or 'openai' as the service; 'nango' is the default. ```javascript const scriptsConfig = await nango.getScriptsConfig('openai'); ``` -------------------------------- ### Get a provider Source: https://nango.dev/docs/reference/sdks/node Returns details for a specific Nango provider by its name. ```APIDOC ## Get a provider ### Description Returns a specific provider's details. ### Method `nango.getProvider({ provider: NAME })` ### Parameters #### Path Parameters - **provider** (string) - required - The name of the provider to retrieve. ### Response #### Success Response (200) - **data** (object) - The provider object. - Contains fields like **name**, **categories**, **auth_mode**, **proxy**, and **docs**. ### Response Example ```json { "data": { "name": "posthog", "categories": ["dev-tools"], "auth_mode": "API_KEY", "proxy": { "base_url": "https://api.posthog.com" }, "docs": "https://nango.dev/docs/api-integrations/posthog" } } ``` ``` -------------------------------- ### Example Response for Prune Records Source: https://nango.dev/docs/reference/sdks/node Shows the response structure after pruning records, indicating the count of pruned records and if more records are available for pruning. ```json { "count": 150, "has_more": true } ``` -------------------------------- ### Show Child Attributes for Github Integration Source: https://nango.dev/docs/reference/sdks/node Displays the attributes for child objects within a specific integration, such as Github issues. This example shows the structure and types of fields available for a 'GithubIssue' model. ```json [ { "providerConfigKey": "demo-github-integration", "syncs": [ { "name": "github-issue-example", "type": "sync", "models": [ { "name": "GithubIssue", "fields": [ { "name": "id", "type": "integer" }, { "name": "owner", "type": "string" }, { "name": "repo", "type": "string" }, { "name": "issue_number", "type": "number" }, { "name": "title", "type": "string" }, { "name": "author", "type": "string" }, { "name": "author_id", "type": "string" }, { "name": "state", "type": "string" }, { "name": "date_created", "type": "date" }, { "name": "date_last_modified", "type": "date" }, { "name": "body", "type": "string" } ] } ], "sync_type": "FULL", "runs": "every half hour", "track_deletes": false, "auto_start": false, "last_deployed": "2024-02-28T20:16:38.052Z", "is_public": false, "pre_built": false, "version": "4", "attributes": {}, "input": {}, "returns": [ "GithubIssue" ], "description": "Fetches the Github issues from all a user's repositories.\nDetails: doesn't track deletes, metadata is not required.\n", "scopes": [ "public_repo" ], "endpoints": [ { "GET": "/github/issue-example" } ], "nango_yaml_version": "v2", "webhookSubscriptions": [] } ], "actions": [ { "name": "fetch-issues", "type": "action", "models": [ { "name": "GithubIssue", "fields": [ { "name": "id", "type": "integer" }, { "name": "owner", "type": "string" }, { "name": "repo", "type": "string" }, { "name": "issue_number", "type": "number" }, { "name": "title", "type": "string" }, { "name": "author", "type": "string" }, { "name": "author_id", "type": "string" }, { "name": "state", "type": "string" }, { "name": "date_created", "type": "date" } ] } ] } ] } ] ``` -------------------------------- ### Get a Specific Integration Source: https://nango.dev/docs/reference/sdks/node Retrieve details for a specific integration using its unique key. The older method using integration ID is deprecated. ```javascript await nango.getIntegration({ uniqueKey: }); // Deprecated await nango.getIntegration(); ``` -------------------------------- ### Create Calendar Event Source: https://nango.dev/docs/reference/sdks/node Creates a new calendar event with specified details. This function allows setting the event's title, description, location, start and end times, attendees, recurrence rules, and associating it with a specific calendar. ```APIDOC ## create-calendar-event ### Description Create a new calendar event. ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **id** (string) - Required - Calendar identifier - **summary** (string) - Required - The title/summary of the event - **description** (string) - Optional - A detailed description of the event - **location** (string) - Optional - The location of the event - **start** (string) - Required - The start time of the event in ISO format - **end** (string) - Required - The end time of the event in ISO format - **attendees** (array) - Optional - List of email addresses to invite - **recurrence** (array) - Optional - List of recurrence rules in RRULE format - **calendar** (string) - Optional - Calendar ID to create the event in - **timeZone** (string) - Optional - Time zone of the calendar - **backgroundColor** (string) - Optional - Calendar color in UI - **foregroundColor** (string) - Optional - Text color in UI - **selected** (boolean) - Optional - Whether the calendar is selected in UI - **accessRole** (string) - Optional - User's access role for the calendar - **primary** (boolean) - Optional - Whether this is the primary calendar ### Request Example ```json { "id": "calendar-id-123", "summary": "Team Meeting", "description": "Discuss project progress", "location": "Conference Room A", "start": "2024-07-26T10:00:00Z", "end": "2024-07-26T11:00:00Z", "attendees": ["user1@example.com", "user2@example.com"], "recurrence": ["RRULE:FREQ=WEEKLY;BYDAY=FR"] } ``` ### Response #### Success Response (200) * **id** (string) - The ID of the created event. * **status** (string) - The status of the event creation. #### Response Example ```json { "id": "event-id-abc", "status": "created" } ``` ``` -------------------------------- ### Get Synced Records with Nango SDK Source: https://nango.dev/docs/reference/sdks/node Retrieve synced records for a specific integration, connection, and model. Supports filtering, pagination, and fetching specific variants. ```typescript import type { ModelName } from '/models' const records = await nango.listRecords({ providerConfigKey: '', connectionId: '', model: '' }); ``` -------------------------------- ### Start Sample App Source: https://nango.dev/docs/getting-started/use-cases/sample-app Launch the sample application. Access it via the provided local URL. ```sh npm run start ``` -------------------------------- ### Proxy GET Request cURL Example Source: https://nango.dev/docs/reference/api/proxy/get Use this cURL command to initiate a proxy GET request. Ensure you replace placeholders with your actual token, connection ID, and provider configuration key. ```bash curl --request GET \ --url https://api.nango.dev/proxy/{anyPath} \ --header 'Authorization: Bearer ' \ --header 'Connection-Id: ' \ --header 'Provider-Config-Key: ' ``` -------------------------------- ### Navigate to Sample App Directory Source: https://nango.dev/docs/getting-started/sample-app Change the current directory to the cloned sample app folder. ```bash cd sample-app ``` -------------------------------- ### Get Async Action Result Source: https://nango.dev/docs/reference/sdks/node Retrieves the result of an asynchronous action using either its ID or status URL. This allows you to check the status and fetch the output of a previously triggered async action. ```javascript // Using the id const result = await nango.getAsyncActionResult({ id: 'action_123456' }); // OR using the statusUrl const result = await nango.getAsyncActionResult({ statusUrl: '/action/action_123456' }); ``` -------------------------------- ### Clone and Install Sample App Source: https://nango.dev/docs/getting-started/use-cases/sample-app Clone the sample application repository and install its dependencies using Node Package Manager. ```sh git clone https://github.com/NangoHQ/sample-app.git cd sample-app nvm use npm i ``` -------------------------------- ### Move Calendar Event Source: https://nango.dev/docs/reference/sdks/node Moves an existing calendar event to a new time or calendar. This function allows updating the event's start and end times, and optionally changing the associated calendar. ```APIDOC ## move-event ### Description Move an event to a different time or calendar. ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **eventId** (string) - Required - The ID of the event to move - **sourceStart** (string) - Required - The current start time of the event - **start** (string) - Required - The new start time for the event in ISO format - **end** (string) - Required - The new end time for the event in ISO format - **calendar** (string) - Optional - Calendar ID to move the event to - **id** (string) - Optional - Calendar identifier - **summary** (string) - Optional - Calendar name/title - **description** (string) - Optional - Calendar description - **location** (string) - Optional - Calendar location - **timeZone** (string) - Optional - Time zone of the calendar - **backgroundColor** (string) - Optional - Calendar color in UI - **foregroundColor** (string) - Optional - Text color in UI - **selected** (boolean) - Optional - Whether the calendar is selected in UI - **accessRole** (string) - Optional - User's access role for the calendar - **primary** (boolean) - Optional - Whether this is the primary calendar ### Request Example ```json { "eventId": "event-id-abc", "sourceStart": "2024-07-26T10:00:00Z", "start": "2024-07-27T14:00:00Z", "end": "2024-07-27T15:00:00Z", "calendar": "new-calendar-id-456" } ``` ### Response #### Success Response (200) * **status** (string) - The status of the event move operation. #### Response Example ```json { "status": "moved" } ``` ``` -------------------------------- ### Call Monday API (Get Boards) with Node.js SDK Source: https://nango.dev/docs/api-integrations/monday This Node.js snippet demonstrates how to call the Monday API to get boards using the Nango SDK. Install the SDK with `npm i @nangohq/node` and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const response = await nango.post({ endpoint: '/v2', data: { query: 'query { boards(limit: 10) { id name } }' }, providerConfigKey: '', connectionId: '' }); console.log(response.data); ``` -------------------------------- ### Fetch Products using Node.js SDK Source: https://nango.dev/docs/api-integrations/lightspeed-retail This Node.js example demonstrates how to fetch a list of products from the Lightspeed Retail (X-Series) API using the Nango backend SDK. Install the SDK using `npm i @nangohq/node` and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/api/2.0/products', params: { page_size: 10 }, providerConfigKey: '', connectionId: '' }); console.log(JSON.stringify(res.data, null, 2)); ``` -------------------------------- ### Call Valley API with Node.js SDK Source: https://nango.dev/docs/integrations/all/valley-api-key Install Nango's backend SDK and use this Node.js code to make a request to the Valley API. This example fetches a list of campaigns and logs the data. Ensure you have installed the SDK using `npm i @nangohq/node`. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/v1/campaigns/get-all', params: { limit: 10 }, providerConfigKey: '', connectionId: '' }); console.log(JSON.stringify(res.data, null, 2)); ``` -------------------------------- ### Install Node.js SDK Source: https://nango.dev/docs/reference/backend/backend-sdk/node Install the Nango Node.js SDK using npm. ```bash npm i -S @nangohq/node ``` -------------------------------- ### Example Response for Get Connection Source: https://nango.dev/docs/reference/backend/backend-sdk/node Illustrates the structure of the response when fetching a connection, including authentication details and metadata. The 'credentials' object contains sensitive tokens. ```json { "id": 18393, "created_at": "2023-03-08T09:43:03.725Z", "updated_at": "2023-03-08T09:43:03.725Z", "provider_config_key": "github", "connection_id": "1", "credentials": { "type": "OAUTH2", "access_token": "gho_tsXLG73f....", "refresh_token": "gho_fjofu84u9....", "expires_at": "2024-03-08T09:43:03.725Z", "raw": { "access_token": "gho_tsXLG73f....", "refresh_token": "gho_fjofu84u9....", "token_type": "bearer", "scope": "public_repo,user" } }, "connection_config": { "subdomain": "myshop", "realmId": "XXXXX", "instance_id": "YYYYYYY" }, "metadata": { "myProperty": "yes", "filter": "closed=true" } } ``` -------------------------------- ### Install and Initialize Nango CLI Source: https://nango.dev/docs/getting-started/use-cases/sample-app Install the Nango CLI globally and initialize it within your Nango integrations directory. ```sh npm install -g nango cd nango-integrations/ nango init ``` -------------------------------- ### Migrate to POST /connections endpoint Source: https://nango.dev/docs/updates/changelog This example shows the previous structure for the POST /connection endpoint, which requires manual migration to the new /connections endpoint. ```bash curl -X POST https://api.nango.dev/v1/connection \ -H "Authorization: Bearer " \ -H "Content-Type: application/json" \ -d '{ "provider_config_key": "slack", "access_token": "some-access-token", [...] ' ``` -------------------------------- ### Mastra Tool Definition Example Source: https://nango.dev/docs/guides/functions/tool-calling Provides a starting point for defining a tool within the Mastra framework. This snippet shows the necessary imports and the structure for creating a tool. ```typescript import { openai } from '@ai-sdk/openai'; import { Agent } from '@mastra/core/agent'; import { createTool } from '@mastra/core/tools'; import { z } from 'zod'; ``` -------------------------------- ### Retrieve Metadata about the API Key Source: https://nango.dev/docs/integrations/all/cursor This example shows how to retrieve metadata about the API key used to authorize Cursor. It demonstrates how to make a GET request to the /v0/me endpoint. ```APIDOC ## GET /v0/me ### Description Retrieves metadata about the API key used to authorize Cursor. ### Method GET ### Endpoint https://api.nango.dev/proxy/v0/me ### Parameters #### Headers - **Authorization** (string) - Required - Bearer token for authentication. - **Provider-Config-Key** (string) - Required - The integration ID. - **Connection-Id** (string) - Required - The connection ID. ### Request Example ```bash curl -X GET "https://api.nango.dev/proxy/v0/me" \ -H "Authorization: Bearer " \ -H "Provider-Config-Key: " \ -H "Connection-Id: " ``` ### Response #### Success Response (200) - **data** (object) - Contains the metadata about the API key. ### Response Example ```json { "example": "response body" } ``` ``` ```APIDOC ## Nango Node SDK: Get Metadata about API Key ### Description Use the Nango Node SDK to retrieve metadata about the API key used to authorize Cursor. ### Method `nango.get()` ### Parameters - **endpoint** (string) - Required - The API endpoint, e.g., '/v0/me'. - **providerConfigKey** (string) - Required - The integration ID. - **connectionId** (string) - Required - The connection ID. ### Request Example ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/v0/me', providerConfigKey: '', connectionId: '' }); console.log(res.data); ``` ### Response #### Success Response - **data** (object) - Contains the metadata about the API key. ### Response Example ```json { "example": "response body" } ``` ``` -------------------------------- ### Instantiate the backend SDK Source: https://nango.dev/docs/reference/backend/backend-sdk/node Installs and instantiates the Nango Node.js SDK. You need to provide your secret key obtained from the Nango UI. Optionally, you can specify a custom host for local development or self-hosted instances. ```APIDOC ## Instantiate the backend SDK ### Description Installs and instantiates the Nango Node.js SDK. You need to provide your secret key obtained from the Nango UI. Optionally, you can specify a custom host for local development or self-hosted instances. ### Installation ```bash npm i -S @nangohq/node ``` ### Usage ```javascript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); ``` ### Parameters #### Request Body - **config** (object) - Required - Configuration object for the Nango SDK. - **secretKey** (string) - Required - Your Nango secret key. Get this from the Nango UI environment settings. This key should never be shared. - **host** (string) - Optional - The host for the Nango API. Defaults to Nango Cloud. Use `http://localhost:3003` for local development or your instance URL if self-hosting. ``` -------------------------------- ### Call Greenhouse Onboarding API with Node.js SDK Source: https://nango.dev/docs/integrations/all/greenhouse-onboarding This Node.js example demonstrates how to install the Nango SDK and make a request to the Greenhouse Onboarding API to fetch locations. Replace placeholders with your Nango secret key, provider config key, and connection ID. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.post({ endpoint: '/graphql', providerConfigKey: '', connectionId: '', data: { query: `query { locations(first: 10) { pageInfo { hasNextPage endCursor } edges { node { id name address externalId } } } }` } }); console.log(JSON.stringify(res.data, null, 2)); ``` -------------------------------- ### Call LeadMagic API with Node.js SDK Source: https://nango.dev/docs/integrations/all/leadmagic This Node.js example demonstrates how to use the Nango SDK to call the LeadMagic API. Ensure you have installed the SDK using `npm i @nangohq/node`. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/v1/credits', providerConfigKey: '', connectionId: '' }); console.log(res.data); ``` -------------------------------- ### Call Cloudbeds API with Node.js SDK Source: https://nango.dev/docs/api-integrations/cloudbeds This Node.js example demonstrates how to call the Cloudbeds API using the Nango SDK. Ensure you have installed the SDK using `npm i @nangohq/node`. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/api/v1.3/userinfo', providerConfigKey: '', connectionId: '' }); console.log(res.data); ``` -------------------------------- ### Copy Environment File Source: https://nango.dev/docs/getting-started/use-cases/sample-app Copy the example environment file to create a new .env file for your application's configuration. ```sh cp .env.example .env ``` -------------------------------- ### Instantiate the frontend SDK Source: https://nango.dev/docs/reference/frontend/frontend-sdk Initialize the Nango frontend SDK with your connection configuration. This setup is necessary before you can use other SDK methods. ```APIDOC ## Instantiate the frontend SDK Initialize the Nango frontend SDK with your connection configuration. This setup is necessary before you can use other SDK methods. ```ts import Nango from '@nangohq/frontend'; const nango = new Nango({ connectSessionToken: '' }); ``` ### Parameters #### Request Body - **config** (object) - Required - **options** (object) - Required - **publicKey** (string) - Deprecated. Get your public key in the environment settings of the Nango UI. This key is not sensitive. - **host** (string) - Optional. Omitting the host points to Nango Cloud. For local development, use `http://localhost:3003`. Use your instance URL if self-hosting. - **websocketsPath** (string) - Optional. For self-hosted instances only to specify a custom path for the WebSocket connection. - **width** (number) - Optional. Specify a specific width for the OAuth authorization modal. - **height** (number) - Optional. Specify a specific height for the OAuth authorization modal. - **debug** (boolean) - Optional. Print additional console logs to debug authorization issues. ``` -------------------------------- ### Call CrowdStrike API with Node.js SDK Source: https://nango.dev/docs/integrations/all/crowdstrike This Node.js example demonstrates how to install Nango's backend SDK and make a request to the CrowdStrike API to query devices. Replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/devices/queries/devices/v1', providerConfigKey: '', connectionId: '', params: { limit: 10 } }); console.log(JSON.stringify(res.data, null, 2)); ``` -------------------------------- ### Call Ashby API with Node.js SDK Source: https://nango.dev/docs/integrations/all/ashby This Node.js example demonstrates how to use the Nango SDK to call the Ashby API. Install the SDK using 'npm i @nangohq/node' and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); // Lists all candidates in an organization. const res = await nango.post({ endpoint: '/candidate.list', providerConfigKey: '', connectionId: '', data: { limit: 10 } }); console.log(res.data); ``` -------------------------------- ### Call Workday API with Node.js SDK Source: https://nango.dev/docs/api-integrations/workday-refresh-token This Node.js example demonstrates how to use the Nango SDK to fetch data from the Workday API. Install the SDK first, then use your credentials to make the request. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const connectionId = ''; const providerConfigKey = ''; const connection = await nango.getConnection(providerConfigKey, connectionId); const res = await nango.get({ endpoint: `/v1/${connection.connection_config['tenant']}/workers`, providerConfigKey, connectionId }); console.log(JSON.stringify(res.data, null, 2)); ``` -------------------------------- ### Configure Google Project Number Source: https://nango.dev/docs/getting-started/use-cases/sample-app Copy the .env.example file in the front-end directory and configure the GOOGLE_PROJECT_NUMBER. ```sh cd front-end cp .env.example .env ``` -------------------------------- ### Call Statista API with Node.js SDK Source: https://nango.dev/docs/integrations/all/statista This Node.js example demonstrates how to use the Nango SDK to fetch data from the Statista API. Install the SDK using 'npm i @nangohq/node' and replace placeholders with your credentials. ```typescript import { Nango } from '@nangohq/node'; const nango = new Nango({ secretKey: '' }); const res = await nango.get({ endpoint: '/v1/statistics', params: { q: '*', size: 10 }, providerConfigKey: '', connectionId: '' }); console.log(res.data); ``` -------------------------------- ### Use Node Version Manager Source: https://nango.dev/docs/getting-started/sample-app Ensure you are using the correct Node.js version for the sample app using NVM. ```bash nvm use ```