Skip to content
Get started

Get connection (by provider)

connections.get_by_tag(Literal["notion", "google-drive", "onedrive", 4 more]provider, ConnectionGetByTagParams**kwargs) -> ConnectionGetByTagResponse
POST/v3/connections/{provider}/connection

Get connection details with provider and container tags

ParametersExpand Collapse
provider: Literal["notion", "google-drive", "onedrive", 4 more]
One of the following:
"notion"
"google-drive"
"onedrive"
"gmail"
"github"
"web-crawler"
"s3"
container_tags: Sequence[str]

Comma-separated list of container tags to filter connection by

ReturnsExpand Collapse
class ConnectionGetByTagResponse:
id: str
created_at: str
formatdatetime
provider: str
Deprecatedcontainer_tags: Optional[List[str]]
document_limit: Optional[float]
email: Optional[str]
expires_at: Optional[str]
formatdatetime
metadata: Optional[Dict[str, object]]

Get connection (by provider)

import os
from supermemory import Supermemory

client = Supermemory(
    api_key=os.environ.get("SUPERMEMORY_API_KEY"),  # This is the default and can be omitted
)
response = client.connections.get_by_tag(
    provider="notion",
    container_tags=["user_123", "project_123"],
)
print(response.id)
{
  "id": "id",
  "createdAt": "createdAt",
  "provider": "provider",
  "containerTags": [
    "string"
  ],
  "documentLimit": 0,
  "email": "email",
  "expiresAt": "expiresAt",
  "metadata": {
    "foo": "bar"
  }
}
Returns Examples
{
  "id": "id",
  "createdAt": "createdAt",
  "provider": "provider",
  "containerTags": [
    "string"
  ],
  "documentLimit": 0,
  "email": "email",
  "expiresAt": "expiresAt",
  "metadata": {
    "foo": "bar"
  }
}