OAuth Token Import
Manage provider OAuth import information
OAuth Token Import object
Attributes
object
Stringid
StringThe unique identifier for this OAuth import
status
EnumThe current state of the import
note
StringNullableAn optional note associated with the import
metadata
ObjectAdditional metadata associated with the import
connection_id
StringThe ID of the associated OAuth connection
id_token
StringNullableThe ID token associated with the import. Only present when the import is created.
scope
StringNullableThe scope of the OAuth token
token_type
StringNullableThe type of the OAuth token
identifier
StringNullableA hashed identifier for the access token associated with this import for security purposes
created_at
DateTimestamp when the import was created
expires_at
DateNullableTimestamp when the import expires
{"object": "provider_oauth.import","status": "active","metadata": {}}
List provider OAuth imports
List all provider OAuth imports
Query Parameters
limit
NumberOptionalafter
StringOptionalbefore
StringOptionalcursor
StringOptionalorder
EnumOptionalcurl -X GET "https://api.metorial.com/provider-oauth/token-imports" \-H "Authorization: Bearer metorial_sk_..."
Create provider OAuth import
Create a new provider OAuth import
Request Body
note
StringOptionalmetadata
ObjectOptionalA key-value map
access_token
Stringexpires_at
DateOptionalid_token
StringOptionalscope
StringOptionaltoken_type
StringOptionalcurl -X POST "https://api.metorial.com/provider-oauth/token-imports" \-H "Content-Type: application/json" \-H "Authorization: Bearer metorial_sk_..." \-d '{"note": "example_note","metadata": {},"access_token": "example_access_token","expires_at": "2025-12-15T02:58:21.568Z","id_token": "example_id_token","scope": "example_scope","token_type": "example_token_type","server_deployment_id": "example_server_deployment_id"}'
Get provider OAuth import
Get information for a specific provider OAuth import
URL Parameters
take_in_id
StringThe unique identifier for the take_in
curl -X GET "https://api.metorial.com/provider-oauth/token-imports/tak_Rm4Mnheq2bfEPhBhP7SY" \-H "Authorization: Bearer metorial_sk_..."
Update provider OAuth import
Update information for a specific provider OAuth import
URL Parameters
take_in_id
StringThe unique identifier for the take_in
Request Body
note
StringOptionalmetadata
ObjectOptionalA key-value map
access_token
StringOptionalexpires_at
DateOptionalid_token
StringOptionalscope
StringOptionaltoken_type
StringOptionalcurl -X PATCH "https://api.metorial.com/provider-oauth/token-imports/tak_Rm4Mnheq2bfEPhBhP7SY" \-H "Content-Type: application/json" \-H "Authorization: Bearer metorial_sk_..." \-d '{"note": "example_note","metadata": {},"access_token": "example_access_token","expires_at": "2025-12-15T02:58:21.569Z","id_token": "example_id_token","scope": "example_scope","token_type": "example_token_type"}'