curl --request POST \
--url https://api.pipedream.com/v1/connect/{project_id}/oauth_apps \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"app": "<string>",
"client_id": "<string>",
"client_secret": "<string>",
"name": "<string>",
"description": "<string>",
"scopes": [
"<string>"
],
"additional_scopes": [
"<string>"
]
}
'import { PipedreamClient } from "@pipedream/sdk";
const client = new PipedreamClient({
clientId: "YOUR_CLIENT_ID",
clientSecret: "YOUR_CLIENT_SECRET",
projectEnvironment: "YOUR_PROJECT_ENVIRONMENT",
projectId: "YOUR_PROJECT_ID"
});
await client.oauthApps.create({
app: "app",
clientId: "client_id",
clientSecret: "client_secret"
});
from pipedream import Pipedream
client = Pipedream(
project_id="YOUR_PROJECT_ID",
client_id="YOUR_CLIENT_ID",
client_secret="YOUR_CLIENT_SECRET",
)
client.oauth_apps.create(
app="app",
client_id="client_id",
client_secret="client_secret",
)
package com.example.usage;
import com.pipedream.api.BaseClient;
import com.pipedream.api.resources.oauthapps.requests.CreateOauthAppOpts;
public class Example {
public static void main(String[] args) {
BaseClient client = BaseClient.withCredentials("<clientId>", "<clientSecret>")
.projectId("YOUR_PROJECT_ID")
.build()
;
client.oauthApps().create(
CreateOauthAppOpts
.builder()
.app("app")
.clientId("client_id")
.clientSecret("client_secret")
.build()
);
}
}
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.pipedream.com/v1/connect/{project_id}/oauth_apps"
payload := strings.NewReader("{\n \"app\": \"<string>\",\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"scopes\": [\n \"<string>\"\n ],\n \"additional_scopes\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"id": "<string>",
"name_slug": "<string>",
"name": "<string>",
"img_src": "<string>",
"custom_fields_json": "<string>",
"categories": [
"<string>"
],
"featured_weight": 123,
"scope_profiles": [
{
"name": "read_only",
"scopes": [
"<string>"
]
}
],
"client_id": "<string>",
"owner_id": "<string>",
"auth_type": "keys",
"description": "<string>",
"scopes": [
"<string>"
],
"additional_scopes": [
"<string>"
],
"redirect_uri": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": "Throttled"
}Create OAuth client
Register a custom OAuth client for an app
curl --request POST \
--url https://api.pipedream.com/v1/connect/{project_id}/oauth_apps \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"app": "<string>",
"client_id": "<string>",
"client_secret": "<string>",
"name": "<string>",
"description": "<string>",
"scopes": [
"<string>"
],
"additional_scopes": [
"<string>"
]
}
'import { PipedreamClient } from "@pipedream/sdk";
const client = new PipedreamClient({
clientId: "YOUR_CLIENT_ID",
clientSecret: "YOUR_CLIENT_SECRET",
projectEnvironment: "YOUR_PROJECT_ENVIRONMENT",
projectId: "YOUR_PROJECT_ID"
});
await client.oauthApps.create({
app: "app",
clientId: "client_id",
clientSecret: "client_secret"
});
from pipedream import Pipedream
client = Pipedream(
project_id="YOUR_PROJECT_ID",
client_id="YOUR_CLIENT_ID",
client_secret="YOUR_CLIENT_SECRET",
)
client.oauth_apps.create(
app="app",
client_id="client_id",
client_secret="client_secret",
)
package com.example.usage;
import com.pipedream.api.BaseClient;
import com.pipedream.api.resources.oauthapps.requests.CreateOauthAppOpts;
public class Example {
public static void main(String[] args) {
BaseClient client = BaseClient.withCredentials("<clientId>", "<clientSecret>")
.projectId("YOUR_PROJECT_ID")
.build()
;
client.oauthApps().create(
CreateOauthAppOpts
.builder()
.app("app")
.clientId("client_id")
.clientSecret("client_secret")
.build()
);
}
}
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.pipedream.com/v1/connect/{project_id}/oauth_apps"
payload := strings.NewReader("{\n \"app\": \"<string>\",\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"scopes\": [\n \"<string>\"\n ],\n \"additional_scopes\": [\n \"<string>\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"id": "<string>",
"name_slug": "<string>",
"name": "<string>",
"img_src": "<string>",
"custom_fields_json": "<string>",
"categories": [
"<string>"
],
"featured_weight": 123,
"scope_profiles": [
{
"name": "read_only",
"scopes": [
"<string>"
]
}
],
"client_id": "<string>",
"owner_id": "<string>",
"auth_type": "keys",
"description": "<string>",
"scopes": [
"<string>"
],
"additional_scopes": [
"<string>"
],
"redirect_uri": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": "Throttled"
}Authorizations
A short-lived OAuth access token for server-side requests. Generate one via the Generate OAuth Token flow or automatically when initializing the SDK client.
Path Parameters
The project ID, which starts with proj_.
^proj_[a-zA-Z0-9]+$Body
The app's ID or name slug. The app must have custom OAuth clients enabled.
The OAuth client ID registered with the upstream provider
The OAuth client secret. Write-only; never returned in responses.
Display name of the OAuth client
Description of the OAuth client
OAuth scopes to request when users connect through this client
Extra OAuth scopes users may grant on top of the base scopes
Response
OAuth client created
A custom OAuth client (bring your own app), presented as its app's metadata merged with the client's own fields. name and description fall back to the app's when the client doesn't set them. The client secret is write-only and never returned.
Hash ID for the OAuth client
^oa_[0-9A-Za-z]+$The name slug of the target app (see https://pipedream.com/docs/connect/quickstart#find-your-apps-name-slug)
The human-readable name of the app
The URL to the app's logo
A JSON string representing the custom fields for the app
Categories associated with the app
A rough directional ordering of app popularity, subject to changes by Pipedream
Named subsets of the app's OAuth scopes that may be requested when users connect their accounts (via the oauth_scope_profile parameter). Empty for apps that don't define any.
Show child attributes
Show child attributes
The OAuth client ID registered with the upstream provider
Hash ID of the owner: the workspace (o_...) or the project (proj_...)
The authentication type used by the app
keys, oauth, none A short description of the app
OAuth scopes requested when users connect through this client
Extra OAuth scopes users may grant on top of the base scopes
The redirect URI to register with the upstream OAuth provider
Was this page helpful?