(integrations)
- list - Returns a list of integrations including their unique keys and providers as configured in the Nango API.
- create - Create a new integration including its provider configuration, OAuth details if applicable, and associated integration ID.
- update - Edit an integration, specifically tailored for OAuth APIs, updating the provider configuration along with OAuth client ID and secret.
- get - Returns details of a specific integration identified by its provider configuration key, optionally including credentials if specified.
- delete - Deletes a specific integration identified by its provider configuration key.
Returns a list of integrations
import { Nango } from "@speakeasy-sdks/nango";
const nango = new Nango();
async function run() {
const result = await nango.integrations.list();
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
Promise<components.IntegrationsResponse200>
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Create a new integration
import { Nango } from "@speakeasy-sdks/nango";
const nango = new Nango();
async function run() {
const result = await nango.integrations.create({});
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
request |
components.ListIntegrationsRequest | ✔️ | The request object to use for the request. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
Promise<components.IntegrationsResponse200>
Error Object | Status Code | Content Type |
---|---|---|
errors.Response400 | 400 | application/json |
errors.SDKError | 4xx-5xx | / |
Edit an integration (only for OAuth APIs)
import { Nango } from "@speakeasy-sdks/nango";
const nango = new Nango();
async function run() {
const result = await nango.integrations.update({});
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
request |
components.UpdateIntegrationRequest | ✔️ | The request object to use for the request. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
Promise<components.IntegrationsResponse200>
Error Object | Status Code | Content Type |
---|---|---|
errors.Response400 | 400 | application/json |
errors.Response404 | 404 | application/json |
errors.SDKError | 4xx-5xx | / |
Returns a specific integration
import { Nango } from "@speakeasy-sdks/nango";
const nango = new Nango();
async function run() {
const result = await nango.integrations.get("<value>", false);
// Handle the result
console.log(result)
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
providerConfigKey |
string | ✔️ | The integration ID that you created in Nango. |
includeCreds |
boolean | ➖ | If true, the response will contain the client ID, secret, scopes, auth_mode and app link - if applicable. include_creds is false by default. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
Promise<components.GetIntegrationResponse>
Error Object | Status Code | Content Type |
---|---|---|
errors.Response400 | 400 | application/json |
errors.Response404 | 404 | application/json |
errors.SDKError | 4xx-5xx | / |
Deletes a specific integration
import { Nango } from "@speakeasy-sdks/nango";
const nango = new Nango();
async function run() {
await nango.integrations.delete("<value>");
}
run();
Parameter | Type | Required | Description |
---|---|---|---|
providerConfigKey |
string | ✔️ | The integration ID that you created in Nango. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
Promise<void>
Error Object | Status Code | Content Type |
---|---|---|
errors.Response400 | 400 | application/json |
errors.Response404 | 404 | application/json |
errors.SDKError | 4xx-5xx | / |