Skip to content

发起交易拦截申诉

通过该接口可发起交易拦截申诉

请求参数类型描述
sub_mchidstring子商户号
jsonobject声明请求的JSON数据结构
merchant_submit_idstring商户侧申诉单号
submit_datastring商户提交资料内容
record_fieldsobject[]资料项集合
item_idstring资料项ID
field_namestring资料项英文名
namestring资料项中文名
typenumber资料项类型
1 | 2 | 11 | 15 枚举值之一
tipsstring资料项填写提示
placeholderstring输入框占位文案
tooltipstring叹号悬浮提示语
requirednumber是否必须提交
0 | 1 枚举值之一
check_ruleobject校验规则
min_lengthnumber字符串最小长度
max_lengthnumber字符串最大长度
enum_file_extsstring[]限制提交的文件后缀
png | jpg | jpeg 枚举值之一
max_file_sizenumber限制文件提交大小,单位M
enum_keysnumber[]枚举可选的字段枚举值
enum_valuesstring[]展示给商户看的枚举可选的字段列表
relationsobject[]资料项关联规则集合
(不同资料项ID取交集,相同资料项ID不同资料项值取并集)
source_keynumber关联的资料项ID
source_valuestring关联的资料项值
need_encryptboolean提交内容需要加密
php
$instance->v3->transactionBlock->transactionBlockSubmissions->subMchid->_sub_mchid_->postAsync([
  'sub_mchid' => '123000110',
  'json' => [
    'merchant_submit_id' => 'ABC123456789',
    'submit_data'        => \json_encode([
      'record_fields' => [[
        'item_id'      => '',
        'field_name'   => '',
        'name'         => '',
        'type'         => 0,
        'tips'         => '',
        'placeholder'  => '',
        'tooltip'      => '',
        'required'     => 0,
        'check_rule'   => [
          'min_length'     => 0,
          'max_length'     => 0,
          'enum_file_exts' => ['png'],
          'max_file_size'  => 0,
          'enum_keys'      => [1],
          'enum_values'    => ['string'],
        ],
        'relations'    => [[
          'source_key'   => 0,
          'source_value' => '',
        ],],
        'need_encrypt' => true,
      ],],
    ]),
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance->chain('v3/transaction-block/transaction-block-submissions/sub-mchid/{sub_mchid}')->postAsync([
  'sub_mchid' => '123000110',
  'json' => [
    'merchant_submit_id' => 'ABC123456789',
    'submit_data'        => \json_encode([
      'record_fields' => [[
        'item_id'      => '',
        'field_name'   => '',
        'name'         => '',
        'type'         => 0,
        'tips'         => '',
        'placeholder'  => '',
        'tooltip'      => '',
        'required'     => 0,
        'check_rule'   => [
          'min_length'     => 0,
          'max_length'     => 0,
          'enum_file_exts' => ['png'],
          'max_file_size'  => 0,
          'enum_keys'      => [1],
          'enum_values'    => ['string'],
        ],
        'relations'    => [[
          'source_key'   => 0,
          'source_value' => '',
        ],],
        'need_encrypt' => true,
      ],],
    ]),
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$instance['v3/transaction-block/transaction-block-submissions/sub-mchid/{sub_mchid}']->postAsync([
  'sub_mchid' => '123000110',
  'json' => [
    'merchant_submit_id' => 'ABC123456789',
    'submit_data'        => \json_encode([
      'record_fields' => [[
        'item_id'      => '',
        'field_name'   => '',
        'name'         => '',
        'type'         => 0,
        'tips'         => '',
        'placeholder'  => '',
        'tooltip'      => '',
        'required'     => 0,
        'check_rule'   => [
          'min_length'     => 0,
          'max_length'     => 0,
          'enum_file_exts' => ['png'],
          'max_file_size'  => 0,
          'enum_keys'      => [1],
          'enum_values'    => ['string'],
        ],
        'relations'    => [[
          'source_key'   => 0,
          'source_value' => '',
        ],],
        'need_encrypt' => true,
      ],],
    ]),
  ],
])
->then(static function(\Psr\Http\Message\ResponseInterface $response) {
  print_r(json_decode((string) $response->getBody(), true));
})
->wait();
php
$response = $instance->v3->transactionBlock->transactionBlockSubmissions->subMchid->_sub_mchid_->post([
  'sub_mchid' => '123000110',
  'json' => [
    'merchant_submit_id' => 'ABC123456789',
    'submit_data'        => \json_encode([
      'record_fields' => [[
        'item_id'      => '',
        'field_name'   => '',
        'name'         => '',
        'type'         => 0,
        'tips'         => '',
        'placeholder'  => '',
        'tooltip'      => '',
        'required'     => 0,
        'check_rule'   => [
          'min_length'     => 0,
          'max_length'     => 0,
          'enum_file_exts' => ['png'],
          'max_file_size'  => 0,
          'enum_keys'      => [1],
          'enum_values'    => ['string'],
        ],
        'relations'    => [[
          'source_key'   => 0,
          'source_value' => '',
        ],],
        'need_encrypt' => true,
      ],],
    ]),
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance->chain('v3/transaction-block/transaction-block-submissions/sub-mchid/{sub_mchid}')->post([
  'sub_mchid' => '123000110',
  'json' => [
    'merchant_submit_id' => 'ABC123456789',
    'submit_data'        => \json_encode([
      'record_fields' => [[
        'item_id'      => '',
        'field_name'   => '',
        'name'         => '',
        'type'         => 0,
        'tips'         => '',
        'placeholder'  => '',
        'tooltip'      => '',
        'required'     => 0,
        'check_rule'   => [
          'min_length'     => 0,
          'max_length'     => 0,
          'enum_file_exts' => ['png'],
          'max_file_size'  => 0,
          'enum_keys'      => [1],
          'enum_values'    => ['string'],
        ],
        'relations'    => [[
          'source_key'   => 0,
          'source_value' => '',
        ],],
        'need_encrypt' => true,
      ],],
    ]),
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
php
$response = $instance['v3/transaction-block/transaction-block-submissions/sub-mchid/{sub_mchid}']->post([
  'sub_mchid' => '123000110',
  'json' => [
    'merchant_submit_id' => 'ABC123456789',
    'submit_data'        => \json_encode([
      'record_fields' => [[
        'item_id'      => '',
        'field_name'   => '',
        'name'         => '',
        'type'         => 0,
        'tips'         => '',
        'placeholder'  => '',
        'tooltip'      => '',
        'required'     => 0,
        'check_rule'   => [
          'min_length'     => 0,
          'max_length'     => 0,
          'enum_file_exts' => ['png'],
          'max_file_size'  => 0,
          'enum_keys'      => [1],
          'enum_values'    => ['string'],
        ],
        'relations'    => [[
          'source_key'   => 0,
          'source_value' => '',
        ],],
        'need_encrypt' => true,
      ],],
    ]),
  ],
]);
print_r(json_decode((string) $response->getBody(), true));
返回字典类型描述
block_submission_idstring交易拦截申诉ID
submit_timestring提交时间
review_resultstring审核结果
EMPTY | PASS | REJECT 枚举值之一
review_timestring审核时间
review_reject_reasonstring审核驳回原因

参阅 官方文档

Published on the GitHub by TheNorthMemory