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

# 坦桑尼亚先令代付申请

> 坦桑尼亚代付仅支持移动支付（EWALLET），金额范围：1,000-5,000,000。

<div class="flex flex-col gap-4">
  <div class="api-section-heading flex flex-col gap-y-4 w-full">
    <div class="flex items-baseline border-b pb-2.5 border-gray-100 dark:border-gray-800 w-full">
      <h4 class="api-section-heading-title flex-1 mb-0">密钥私钥(生成签名)</h4>
    </div>

    <div />
  </div>

  <input id="secret-key" placeholder="密钥" class="px-3 py-2 border rounded-md" />

  <input id="private-key" placeholder="私钥" class="px-3 py-2 border rounded-md" />
</div>

## 相关主题

* [坦桑尼亚支付接口](/docs/zh/api/version2/Tanzania)
* [HaiPay API 文档简介](/docs/zh/api-reference/overview)
* [HaiPay 配置与签名指南](/docs/zh/guide/config_settings_and_signature_rules_guide)


## OpenAPI

````yaml docs/zh/api-reference/tzs/tzs.openapi.json POST /tzs/pay/apply
openapi: 3.0.1
info:
  title: 默认模块
  description: ''
  version: 1.0.0
servers:
  - url: https://uat-interface.haipay.asia
    description: 测试-interface
security: []
tags: []
paths:
  /tzs/pay/apply:
    post:
      tags: []
      summary: 坦桑尼亚先令代付申请
      description: 坦桑尼亚代付仅支持移动支付（EWALLET），金额范围：1,000-5,000,000。
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                appId:
                  type: integer
                  description: 业务ID（后台获取，需要根据URL中的币种传递对应的业务ID）
                orderId:
                  type: string
                  description: 商户订单号(必须保证唯一性，长度不超过48)
                  maxLength: 48
                amount:
                  type: string
                  description: 交易金额（单位：TSh），最多两位小数，范围：1,000-5,000,000
                accountType:
                  type: string
                  description: 账户类型：EWALLET
                  enum:
                    - EWALLET
                bankCode:
                  type: string
                  description: 支付方式编码：AIRTEL / HALOPESA / TIGO / VODACOM
                accountNo:
                  type: string
                  description: 用户手机号（坦桑尼亚手机号，255开头12位）
                name:
                  type: string
                  description: >-
                    收款人姓名(格式：仅限英文字符，1-30位,"firstName middleName lastName"
                    (middleName 非必填, 不支持特殊字符和数字))
                  minLength: 1
                  maxLength: 30
                phone:
                  type: string
                  description: 真实手机号
                email:
                  type: string
                  description: 真实电子邮件
                  format: email
                notifyUrl:
                  type: string
                  description: 回调地址
                  format: uri
                subject:
                  type: string
                  description: 支付备注（交易标题，商品名称，支付原因）
                body:
                  type: string
                  description: 备注详情
                partnerUserId:
                  type: string
                  description: >-
                    用户唯一标识（如用户ID userId），用于风控系统，必须真实有效，否则会影响交易。
                    格式要求：数字、大小写字母或常用符号-~!@#$%&*()_。
                  pattern: ^[A-Za-z0-9\-~!@#$%&*()_]+$
                sign:
                  type: string
                  description: 签名
              required:
                - appId
                - orderId
                - amount
                - accountType
                - bankCode
                - accountNo
                - name
                - phone
                - email
                - partnerUserId
                - sign
              additionalProperties: false
            example:
              appId: 1054
              orderId: M233323000059
              amount: '5000.00'
              accountType: EWALLET
              bankCode: VODACOM
              accountNo: '255712345678'
              name: John Doe
              phone: '255712345678'
              email: john.doe@example.com
              notifyUrl: https://merchant.com/api/notify
              subject: Payment for order
              body: Premium subscription
              partnerUserId: '149597870'
              sign: >-
                af0gAHkUOyYHu9owQp8NJ4mPEeUW4vuJcjdxqLIzrVw8AvpLSjD1DXupReSG/CyuSkFRyiIvCp5u703AuGGmfgD2gKDH3Ywau41bAbG2jnHJ8mtjiSJ5iWUzanyd4Kr7d1+rETbzUl7/BkW3t0X8UUFdqpxwG8DPUjAwUKfplWDHV7koG51Ozexd80DCsmW6eWdouAZ1uNXGLYmV3ftE3BmfNRtuv1C5bfTJWrTEIOxbF6g2uYOFZTlIgrQgd7/2PsAYwQQXNz8Q8CYl4OxqCv4pXJxaLWPbR5tqZu9og5kn32C9aHW/NlU1y39vzz+4ef81yPAqUV9oHlSMSPrMmw==
        required: true
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    description: 状态码
                  error:
                    type: string
                    description: 错误码
                  msg:
                    type: string
                    description: 提示信息
                  data:
                    type: object
                    properties:
                      orderId:
                        type: string
                        description: 商户订单号(必须保证唯一性)
                      orderNo:
                        type: string
                        description: 平台订单号
                      sign:
                        type: string
                        description: 签名
                    additionalProperties: true
                additionalProperties: true
              example:
                status: '1'
                error: '00000000'
                msg: success
                data:
                  orderId: M233323000059
                  orderNo: '6023071013539074'
                  sign: >-
                    af0gAHkUOyYHu9owQp8NJ4mPEeUW4vuJcjdxqLIzrVw8AvpLSjD1DXupReSG/CyuSkFRyiIvCp5u703AuGGmfgD2gKDH3Ywau41bAbG2jnHJ8mtjiSJ5iWUzanyd4Kr7d1+rETbzUl7/BkW3t0X8UUFdqpxwG8DPUjAwUKfplWDHV7koG51Ozexd80DCsmW6eWdouAZ1uNXGLYmV3ftE3BmfNRtuv1C5bfTJWrTEIOxbF6g2uYOFZTlIgrQgd7/2PsAYwQQXNz8Q8CYl4OxqCv4pXJxaLWPbR5tqZu9og5kn32C9aHW/NlU1y39vzz+4ef81yPAqUV9oHlSMSPrMmw==
      deprecated: false
      security: []

````