3

我是 Klarna 的初学者,正在尝试开始。

使用邮递员,我试图通过对https://api-na.playground.klarna.com/payments/v1/sessions进行 POST 来创建会话。我正在使用 HTTP 基本身份验证。

以下是请求和响应。你能帮我弄清楚我做错了什么。

请求标头:

Accept: */*
Klarna-Correlation-Id: 45021dd4-b216-417a-a8e7-85f2447a936d
User-Agent: PostmanRuntime/7.4.0
Host: api-na.playground.klarna.com
Accept-Encoding: gzip, deflate
Content-Length: 495
Content-Type: application/json

请求正文(带有测试数据):

{
    "purchase_country": "us",
    "purchase_currency": "usd",
    "locale": "en-US",
    "order_amount": 1000,
    "order_tax_amount": 0,
    "order_lines": [
        {
            "type": "physical",
            "reference": "19-402-USA",
            "name": "Battery Power Pack",
            "quantity": 1,
            "unit_price": 1000,
            "tax_rate": 0,
            "total_amount": 1000,
            "total_discount_amount": 0,
            "total_tax_amount": 0
        }
    ]
}

回复:

{
    "error_code": "INVALID_OPERATION",
    "error_messages": [
      ""
    ],
    "correlation_id": "45021dd4-b216-417a-a8e7-85f2447a936d"
}
4

0 回答 0