2024-06-19 13:41:12 +08:00
|
|
|
from typing import Optional
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
from pydantic import Field
|
|
|
|
from pydantic_settings import BaseSettings
|
2024-06-19 13:41:12 +08:00
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class NotionConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration settings for Notion integration
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
NOTION_CLIENT_ID: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Client ID for Notion API authentication. Required for OAuth 2.0 flow.",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
NOTION_CLIENT_SECRET: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Client secret for Notion API authentication. Required for OAuth 2.0 flow.",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
NOTION_INTEGRATION_TYPE: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Type of Notion integration."
|
|
|
|
" Set to 'internal' for internal integrations, or None for public integrations.",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
NOTION_INTERNAL_SECRET: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Secret key for internal Notion integrations. Required when NOTION_INTEGRATION_TYPE is 'internal'.",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
NOTION_INTEGRATION_TOKEN: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Integration token for Notion API access. Used for direct API calls without OAuth flow.",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|