Estou com dificuldades para Identificar o campo responsável pelo armazenamento do saldo da carteira virtual do cliente.
Ex: GSV-1529360531190-01
Dificuldade:
Identificar a API e o respetivo campo;
-
Tentativa 1:
Ao fazer uma requisição get, usou-se o seguinte código para mapeamento do possível campo ao endpoint:
order_id_desejado = “GSV-1529360531190-01”
url = f’https://servelec291.vtexcommercestable.com.br/api/oms/pvt/orders/ {order_id_desejado}’
taxas_item = item.get(‘taxData’, {}).get(‘taxInfoCollection’, [{}])[0].get(‘priceTags’, [{}])[0].get(‘rawValue’, 0)
“taxData”: {
“areTaxesDesignatedByMarketplace”: true,
“taxInfoCollection”: [
{
“itemIndex”: 0,
“sku”: “18”,
“priceTags”:[
{
“identifier”: “0a9df101-330c-41ad-a4c7-5a0bd521bc9u”,
“isPercentual”: false,
“name”: “Taxes (Magazine Luisa)”,
“value”: 193,
“rawValue”: 1.93
}
]
}
]
}
→ Tentativa 2:
Buscar o valor (Taxes) na API Promotions & Taxes
url = “https://servelec291.vtexcommercestable.com.br/api/rnb/pvt/taxes/calculatorconfiguration”
Neste caso tenho o seguinte Json como resposta: Nos (itens activos) retorna-me “0”
{
“limitConfiguration”: {
“activesCount”: 0,
“limit”: 100
},
“items”: ,
“disabledItems”: ,
“archivedItems”:
}
Obrigado,
Melhores Cumprimentos.