邮递员 API - 状态代码 400 - params":{"__all__":"invalid price quote"}
Postmates API - Status Code 400 - params":{"__all__":"invalid price quote"}
我正在尝试使用 firebase 将 post 连接到 /v1/customers/:customer_id/deliveries
端点。我从 angular 应用程序发送查询参数。
查询对象
{
pickup_name: 'Patrick O',
pickup_phone_number: '619-***-****',
dropoff_name: 'Wendell And Chad',
dropoff_phone_number: '619-***-****',
manifest: 'Cheese',
quote_id: 'Mc26u6TwH_qKkF',
dropoff_address: '4606 Market Street, San Diego, CA',
pickup_address: '1041 Market Street, San Diego, CA'
}
响应(Firebase 函数)
Unhandled error { StatusCodeError: 400 - {"kind":"error","code":"invalid_params","message":"The parameters of your request were invalid.","params":{"__all__":"invalid price quote"}}
...
name: 'StatusCodeError',
statusCode: 400,
message: '400 - {"kind":"error","code":"invalid_params","message":"The parameters of your request were invalid.","params":{"__all__":"invalid price quote"}}',
error:
{ kind: 'error',
code: 'invalid_params',
message: 'The parameters of your request were invalid.',
params: { __all__: 'invalid price quote' } }, ...
我在 Postmates Api 文档中没有遇到 __all__
的错误。感谢您的时间和考虑。
问题已通过从查询参数
中删除 quote_id 属性 得到解决
查询对象
{
pickup_name: 'Patrick O',
pickup_phone_number: '619-***-****',
dropoff_name: 'Wendell And Chad',
dropoff_phone_number: '619-***-****',
manifest: 'Cheese',
dropoff_address: '4606 Market Street, San Diego, CA',
pickup_address: '1041 Market Street, San Diego, CA'
}
我没有测试过,但我相信 quote_id 属性 可以使用,但字符串必须是完整的引用 ID。
quote_id: 'dqt_Mc26u6TwH_qKkF',
与我拥有的 quote_id: 'Mc26u6TwH_qKkF',
相反。
后面的我核实后再更新答案
我正在尝试使用 firebase 将 post 连接到 /v1/customers/:customer_id/deliveries
端点。我从 angular 应用程序发送查询参数。
查询对象
{
pickup_name: 'Patrick O',
pickup_phone_number: '619-***-****',
dropoff_name: 'Wendell And Chad',
dropoff_phone_number: '619-***-****',
manifest: 'Cheese',
quote_id: 'Mc26u6TwH_qKkF',
dropoff_address: '4606 Market Street, San Diego, CA',
pickup_address: '1041 Market Street, San Diego, CA'
}
响应(Firebase 函数)
Unhandled error { StatusCodeError: 400 - {"kind":"error","code":"invalid_params","message":"The parameters of your request were invalid.","params":{"__all__":"invalid price quote"}}
...
name: 'StatusCodeError',
statusCode: 400,
message: '400 - {"kind":"error","code":"invalid_params","message":"The parameters of your request were invalid.","params":{"__all__":"invalid price quote"}}',
error:
{ kind: 'error',
code: 'invalid_params',
message: 'The parameters of your request were invalid.',
params: { __all__: 'invalid price quote' } }, ...
我在 Postmates Api 文档中没有遇到 __all__
的错误。感谢您的时间和考虑。
问题已通过从查询参数
中删除 quote_id 属性 得到解决查询对象
{
pickup_name: 'Patrick O',
pickup_phone_number: '619-***-****',
dropoff_name: 'Wendell And Chad',
dropoff_phone_number: '619-***-****',
manifest: 'Cheese',
dropoff_address: '4606 Market Street, San Diego, CA',
pickup_address: '1041 Market Street, San Diego, CA'
}
我没有测试过,但我相信 quote_id 属性 可以使用,但字符串必须是完整的引用 ID。
quote_id: 'dqt_Mc26u6TwH_qKkF',
与我拥有的 quote_id: 'Mc26u6TwH_qKkF',
相反。
后面的我核实后再更新答案