Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to get MFN Eligible Shipment Services #365

Closed
quanlndzt opened this issue Apr 27, 2024 · 1 comment
Closed

Unable to get MFN Eligible Shipment Services #365

quanlndzt opened this issue Apr 27, 2024 · 1 comment

Comments

@quanlndzt
Copy link

Hey team
I try to get MFN Eligible Shipment via api but it not work
API :

{{baseUrl}}/mfn/v0/eligibleShippingServices

Request body:

{
  "ShipmentRequestDetails": {
    "AmazonOrderId": "112-3861871-6830603",
    "ItemList": [
      {
        "OrderItemId": "97755198622321",
        "Quantity": 1,
        "ItemWeight": {
          "Unit": "lb",
          "Value":10
        },
        "ItemDescription": "My test item"
      }
    ],
    "PackageDimensions": {
      "Length": 100,
      "Width": 100,
      "Height": 50,
      "Unit": "centimeters",
      "PredefinedPackageDimensions": "FedEx_Pak_1"
    },
    "ShipFromAddress": {
      "AddressLine1": "so 100",
      "City": "Ha Noi",
      "CountryCode": "VN",
      "Email": "test@example.com",
      "Name": "Test stock",
      "Phone": "0987654321",
      "PostalCode": "100000",
      "AddressLine2": "Dich Vong Hau",
      "AddressLine3": "Cau Giay"
    },
    "Weight": {
      "Unit": "g",
      "Value": 222
    },
    "SellerOrderId": "test-seller-order-id",
    "LabelCustomization": {
      "CustomTextForLabel": "Test MFN",
      "StandardIdForLabel": "112-3861871-6830603"
    }
  },
  "ShippingOfferingFilter": {
    "IncludePackingSlipWithLabel": false,
    "CarrierWillPickUp": "CarrierWillPickUp"
  }
}

And I got error

{
    "errors": [
        {
            "code": "Unauthorized",
            "message": "Access to requested resource is denied.",
            "details": ""
        }
    ]
}

My api key seem have permission to it
image

Please help me fix this issue
Thank you

@shreeharsh-a
Copy link
Contributor

Hi @quanlndzt,
Per the docs, you will need access to the Direct to Consumer Shipping (Restricted) role to access this API (see under section Prerequisites).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants