curl --request GET \
--url https://api.pipedream.com/v1/connect/{project_id}/accounts/{account_id} \
--header 'Authorization: Bearer <token>' \
--header 'x-pd-environment: <x-pd-environment>'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.accounts.retrieve("account_id", {
includeCredentials: true
});
from pipedream import Pipedream
client = Pipedream(
project_id="YOUR_PROJECT_ID",
client_id="YOUR_CLIENT_ID",
client_secret="YOUR_CLIENT_SECRET",
)
client.accounts.retrieve(
account_id="account_id",
include_credentials=True,
)
package com.example.usage;
import com.pipedream.api.BaseClient;
import com.pipedream.api.resources.accounts.requests.AccountsRetrieveRequest;
public class Example {
public static void main(String[] args) {
BaseClient client = BaseClient.withCredentials("<clientId>", "<clientSecret>")
.projectId("YOUR_PROJECT_ID")
.build()
;
client.accounts().retrieve(
"account_id",
AccountsRetrieveRequest
.builder()
.includeCredentials(true)
.build()
);
}
}
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.pipedream.com/v1/connect/{project_id}/accounts/{account_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-pd-environment", "<x-pd-environment>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"id": "<string>",
"name": "<string>",
"external_id": "<string>",
"healthy": true,
"dead": true,
"app": {
"name_slug": "<string>",
"name": "<string>",
"img_src": "<string>",
"custom_fields_json": "<string>",
"categories": [
"<string>"
],
"featured_weight": 123,
"scope_profiles": [
{
"name": "read_only",
"scopes": [
"<string>"
]
}
],
"id": "<string>",
"auth_type": "keys",
"description": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"authorized_scopes": [
"<string>"
],
"credentials": {
"oauth_client_id": "<string>",
"oauth_access_token": "<string>",
"oauth_refresh_token": "<string>",
"oauth_uid": "<string>",
"oauth_signer_uri": "<string>"
},
"expires_at": "2023-11-07T05:31:56Z",
"error": "<string>",
"last_refreshed_at": "2023-11-07T05:31:56Z",
"next_refresh_at": "2023-11-07T05:31:56Z"
}{
"error": "Throttled"
}Retrieve account
Get the details for a specific connected account
curl --request GET \
--url https://api.pipedream.com/v1/connect/{project_id}/accounts/{account_id} \
--header 'Authorization: Bearer <token>' \
--header 'x-pd-environment: <x-pd-environment>'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.accounts.retrieve("account_id", {
includeCredentials: true
});
from pipedream import Pipedream
client = Pipedream(
project_id="YOUR_PROJECT_ID",
client_id="YOUR_CLIENT_ID",
client_secret="YOUR_CLIENT_SECRET",
)
client.accounts.retrieve(
account_id="account_id",
include_credentials=True,
)
package com.example.usage;
import com.pipedream.api.BaseClient;
import com.pipedream.api.resources.accounts.requests.AccountsRetrieveRequest;
public class Example {
public static void main(String[] args) {
BaseClient client = BaseClient.withCredentials("<clientId>", "<clientSecret>")
.projectId("YOUR_PROJECT_ID")
.build()
;
client.accounts().retrieve(
"account_id",
AccountsRetrieveRequest
.builder()
.includeCredentials(true)
.build()
);
}
}
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.pipedream.com/v1/connect/{project_id}/accounts/{account_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-pd-environment", "<x-pd-environment>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"id": "<string>",
"name": "<string>",
"external_id": "<string>",
"healthy": true,
"dead": true,
"app": {
"name_slug": "<string>",
"name": "<string>",
"img_src": "<string>",
"custom_fields_json": "<string>",
"categories": [
"<string>"
],
"featured_weight": 123,
"scope_profiles": [
{
"name": "read_only",
"scopes": [
"<string>"
]
}
],
"id": "<string>",
"auth_type": "keys",
"description": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"authorized_scopes": [
"<string>"
],
"credentials": {
"oauth_client_id": "<string>",
"oauth_access_token": "<string>",
"oauth_refresh_token": "<string>",
"oauth_uid": "<string>",
"oauth_signer_uri": "<string>"
},
"expires_at": "2023-11-07T05:31:56Z",
"error": "<string>",
"last_refreshed_at": "2023-11-07T05:31:56Z",
"next_refresh_at": "2023-11-07T05:31:56Z"
}{
"error": "Throttled"
}Authorizations
A short-lived Connect token for client-side requests on behalf of an end user. Generate one via the Create Connect token endpoint.
Headers
The environment in which the server client is running
development, production Path Parameters
The project ID, which starts with proj_.
^proj_[a-zA-Z0-9]+$Query Parameters
Whether to retrieve the account's credentials or not
Response
account retrieved
End user account data, returned from the API.
The unique ID of the account.
^apn_[a-zA-Z0-9]+$The custom name of the account if set.
The external ID associated with the account.
Indicates if the account is healthy. Pipedream will periodically retry token refresh and test requests for unhealthy accounts
Indicates if the account is no longer active
Response object for a Pipedream app's metadata
Show child attributes
Show child attributes
The date and time the account was created, an ISO 8601 formatted string
The date and time the account was last updated, an ISO 8601 formatted string
The OAuth scopes effectively granted to this account. Empty for non-OAuth apps.
The credentials associated with the account, if the include_credentials parameter was set to true in the request (only applicable for BYOA apps). In addition to the well-known OAuth fields listed below, this object may contain app-specific custom fields (e.g. base_url).
Show child attributes
Show child attributes
The date and time the account's credentials expiration, an ISO 8601 formatted string
The error message if the account is unhealthy or dead, null otherwise
The date and time the account was last refreshed, an ISO 8601 formatted string
The date and time the account will next be refreshed, an ISO 8601 formatted string
Was this page helpful?