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

# 创建交易

> 创建交易（商机）。



## OpenAPI

````yaml openapi/zh/apollo.json POST /apollo/opportunities
openapi: 3.0.3
info:
  title: Apollo API
  version: 1.0.0
  description: 通过 AIsa 统一网关公开的 Apollo API 端点。
servers:
  - url: https://api.aisa.one/apis/v1
security:
  - BearerAuth: []
paths:
  /apollo/opportunities:
    post:
      summary: 创建交易
      description: 创建交易（商机）。需要主 API 密钥。
      operationId: post_apollo_opportunities
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 交易名称
                owner_id:
                  type: string
                  description: 所有者 ID
                account_id:
                  type: string
                  description: 账户 ID
                amount:
                  type: number
                  description: 交易金额
                opportunity_stage_id:
                  type: string
                  description: 交易阶段 ID
                closed_date:
                  type: string
                  description: 关闭日期（日期字符串）
                typed_custom_fields:
                  type: object
                  description: 类型化自定义字段对象
              required:
                - name
      responses:
        '200':
          description: 成功响应
          content:
            application/json:
              schema:
                type: object
                properties:
                  opportunity:
                    type: object
                    description: 已创建的商机
                    additionalProperties: true
        '400':
          description: 错误请求
        '401':
          description: 未授权
        '429':
          description: 超出速率限制
        '500':
          description: 内部服务器错误
components:
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````