> ## Documentation Index
> Fetch the complete documentation index at: https://phaseo.app/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# تحديث إعدادات الإشعارات

> يحدّث قسماً واحداً أو أكثر من سياسة الإشعارات الدائمة. يتطلب تفعيل التعبئة التلقائية معرّفاً موجوداً لطريقة دفع محفوظة ومصادقة ثنائية موثقة. يمكن تحديث إعداد قائم دون تكرار إقرار MFA. للتفعيل دون MFA يجب على العملاء تعيين `mfa_bypass_acknowledged` صراحةً إلى true وتوفير القيمة الدقيقة `I ACCEPT THE RISK` للحقل `mfa_bypass_phrase`؛ يظل جمع معلومات الدفع إجراءً تفاعلياً في الحساب.

<Note />


## OpenAPI

````yaml ar/openapi/v1/openapi.localized.yaml PATCH /notifications/settings
openapi: 3.0.3
info:
  title: Phaseo Gateway API
  description: >-
    واجهة API للبوابة تتيح الوصول إلى نماذج ذكاء اصطناعي متنوعة عبر نقاط نهاية
    متوافقة مع OpenAI.
  version: 1.0.0
  contact:
    name: Phaseo
    url: https://phaseo.app
    email: danielbutler500@gmail.com
servers:
  - url: https://api.phaseo.app/v1
    description: التوجيه العالمي
security:
  - BearerAuth: []
tags:
  - name: Gateway
    description: Core Phaseo Gateway operations.
paths:
  /notifications/settings:
    patch:
      tags:
        - Gateway
      summary: تحديث إعدادات إشعارات مساحة العمل
      description: >-
        يحدّث قسماً واحداً أو أكثر من سياسة الإشعارات الدائمة. يتطلب تفعيل
        التعبئة التلقائية معرّفاً موجوداً لطريقة دفع محفوظة ومصادقة ثنائية
        موثقة. يمكن تحديث إعداد قائم دون تكرار إقرار MFA. للتفعيل دون MFA يجب
        على العملاء تعيين `mfa_bypass_acknowledged` صراحةً إلى true وتوفير
        القيمة الدقيقة `I ACCEPT THE RISK` للحقل `mfa_bypass_phrase`؛ يظل جمع
        معلومات الدفع إجراءً تفاعلياً في الحساب.
      operationId: updateWorkspaceNotificationSettings
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspaceNotificationSettingsUpdateRequest'
      responses:
        '200':
          description: تم تحديث إعدادات الإشعارات
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkspaceNotificationSettingsResponse'
        default:
          description: فشل الطلب
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security: []
components:
  schemas:
    WorkspaceNotificationSettingsUpdateRequest:
      type: object
      minProperties: 1
      properties:
        auto_top_up:
          $ref: '#/components/schemas/WorkspaceAutoTopUpUpdate'
        low_balance_email:
          $ref: '#/components/schemas/WorkspaceLowBalanceEmailUpdate'
        email_preferences:
          $ref: '#/components/schemas/WorkspaceNotificationEmailPreferencesUpdate'
      additionalProperties: false
    WorkspaceNotificationSettingsResponse:
      type: object
      required:
        - data
      properties:
        data:
          $ref: '#/components/schemas/WorkspaceNotificationSettings'
      additionalProperties: false
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        ok:
          type: boolean
          example: false
        error:
          oneOf:
            - type: string
            - type: object
              additionalProperties: true
          example: error_type
        message:
          type: string
          example: Human-readable error message
        description:
          type: string
          example: Additional error details.
        generation_id:
          type: string
          example: G-abc123
        status_code:
          type: integer
          example: 502
        error_type:
          type: string
          enum:
            - user
            - system
          example: system
        error_origin:
          type: string
          enum:
            - user
            - gateway
            - upstream
          example: upstream
        reason:
          type: string
          example: all_candidates_failed
        attempt_count:
          type: integer
          example: 2
        failed_providers:
          type: array
          items:
            type: string
          example:
            - google-ai-studio
            - openai
        failed_statuses:
          type: array
          items:
            type: integer
          example:
            - 403
            - 429
        upstream_error:
          $ref: '#/components/schemas/ErrorUpstreamError'
        failure_sample:
          type: array
          items:
            $ref: '#/components/schemas/ErrorFailureSampleItem'
        provider_failure_diagnostics:
          $ref: '#/components/schemas/ErrorProviderFailureDiagnostics'
        routing_diagnostics:
          $ref: '#/components/schemas/ErrorRoutingDiagnostics'
        provider_candidate_diagnostics:
          $ref: '#/components/schemas/ErrorProviderCandidateDiagnostics'
        provider_enablement:
          $ref: '#/components/schemas/ErrorProviderEnablementDiagnostics'
        missing_pricing_providers:
          type: array
          items:
            type: string
        provider_payment_required_provider:
          type: string
          example: openai
        provider_payment_required_support_notice:
          type: string
          example: >-
            Our upstream provider billing appears to be unavailable. If this
            persists, contact support.
        details:
          type: array
          items:
            type: object
            additionalProperties: true
      additionalProperties: true
    WorkspaceAutoTopUpUpdate:
      type: object
      required:
        - enabled
      properties:
        enabled:
          type: boolean
        balance_threshold_nanos:
          type: integer
          minimum: 0
        amount_nanos:
          type: integer
          minimum: 0
        payment_method_id:
          type: string
          nullable: true
        mfa_bypass_acknowledged:
          type: boolean
        mfa_bypass_phrase:
          type: string
      additionalProperties: false
    WorkspaceLowBalanceEmailUpdate:
      type: object
      required:
        - enabled
      properties:
        enabled:
          type: boolean
        threshold_usd:
          type: number
          minimum: 0
          multipleOf: 0.01
      additionalProperties: false
    WorkspaceNotificationEmailPreferencesUpdate:
      type: object
      minProperties: 1
      properties:
        auto_top_up_failure:
          type: boolean
        payment_method_expiring:
          type: boolean
        model_deprecation:
          type: boolean
      additionalProperties: false
    WorkspaceNotificationSettings:
      type: object
      required:
        - auto_top_up
        - low_balance_email
        - email_preferences
      properties:
        auto_top_up:
          $ref: '#/components/schemas/WorkspaceAutoTopUpSettings'
        low_balance_email:
          $ref: '#/components/schemas/WorkspaceLowBalanceEmailSettings'
        email_preferences:
          $ref: '#/components/schemas/WorkspaceNotificationEmailPreferences'
      additionalProperties: false
    ErrorUpstreamError:
      type: object
      properties:
        code:
          type: string
          nullable: true
          example: PERMISSION_DENIED
        message:
          type: string
          nullable: true
          example: The caller does not have permission.
        description:
          type: string
          nullable: true
        param:
          type: string
          nullable: true
    ErrorFailureSampleItem:
      type: object
      properties:
        provider:
          type: string
          nullable: true
        type:
          type: string
          nullable: true
        status:
          type: integer
          nullable: true
        upstream_error_code:
          type: string
          nullable: true
        upstream_error_message:
          type: string
          nullable: true
        upstream_error_description:
          type: string
          nullable: true
        upstream_error_param:
          type: string
          nullable: true
        upstream_payload_preview:
          type: string
          nullable: true
        retryable:
          type: boolean
          nullable: true
      additionalProperties: true
    ErrorProviderFailureDiagnostics:
      type: object
      properties:
        category:
          type: string
          enum:
            - credentials_not_configured
            - credentials_invalid_or_forbidden
            - provider_access_missing
            - region_or_project_restriction
            - model_unavailable_for_endpoint
            - rate_limited
            - server_error
        hint:
          type: string
        provider:
          type: string
          nullable: true
    ErrorRoutingDiagnostics:
      type: object
      properties:
        filterStages:
          type: array
          items:
            type: object
            properties:
              stage:
                type: string
              beforeCount:
                type: integer
              afterCount:
                type: integer
              droppedProviders:
                type: array
                items:
                  type: object
                  properties:
                    providerId:
                      type: string
                      nullable: true
                    reason:
                      type: string
                      nullable: true
                  additionalProperties: true
            additionalProperties: true
      additionalProperties: true
    ErrorProviderCandidateDiagnostics:
      type: object
      properties:
        totalProviders:
          type: integer
        supportsEndpointCount:
          type: integer
        candidateCount:
          type: integer
        droppedUnsupportedEndpoint:
          type: array
          items:
            type: string
        droppedMissingAdapter:
          type: array
          items:
            type: object
            properties:
              providerId:
                type: string
                nullable: true
              endpoint:
                type: string
                nullable: true
            additionalProperties: true
      additionalProperties: true
    ErrorProviderEnablementDiagnostics:
      type: object
      properties:
        capability:
          type: string
        providersBefore:
          type: array
          items:
            type: string
        providersAfter:
          type: array
          items:
            type: string
        dropped:
          type: array
          items:
            type: object
            properties:
              providerId:
                type: string
                nullable: true
              reason:
                type: string
                nullable: true
            additionalProperties: true
      additionalProperties: true
    WorkspaceAutoTopUpSettings:
      type: object
      required:
        - enabled
        - balance_threshold_nanos
        - amount_nanos
        - payment_method_id
      properties:
        enabled:
          type: boolean
        balance_threshold_nanos:
          type: integer
          minimum: 0
        amount_nanos:
          type: integer
          minimum: 0
        payment_method_id:
          type: string
          nullable: true
      additionalProperties: false
    WorkspaceLowBalanceEmailSettings:
      type: object
      required:
        - enabled
        - threshold_usd
      properties:
        enabled:
          type: boolean
        threshold_usd:
          type: number
          minimum: 0
          multipleOf: 0.01
      additionalProperties: false
    WorkspaceNotificationEmailPreferences:
      type: object
      required:
        - auto_top_up_failure
        - payment_method_expiring
        - model_deprecation
      properties:
        auto_top_up_failure:
          type: boolean
        payment_method_expiring:
          type: boolean
        model_deprecation:
          type: boolean
      additionalProperties: false
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: المصادقة باستخدام رمز Bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.