Histórico de mensagens sobre server_error

EXIBINDO CONVERSAS RECENTES:

Texto: server_error
# pix
Avatar discord do usuario igorgoldim

igorgoldim

Ver Respostas

Olá boa tarde, estou recendo este código de retorno para pagamento por cartão de credito, alguém sabe me dizer o que significa???

{"code":3500000,"error":"server_error","error_description":"Erro interno do servidor."}

# pix
Avatar discord do usuario emiliocalvet

emiliocalvet

Ver Respostas

java
public PixChargeResponse pixCreateImmediateCharge(PixChargeRequest pixChargeRequest) {
if (!isValidValue(pixChargeRequest.valor())) {
throw new ResponseStatusException(HttpStatus.BAD_REQUEST, "Valor inválido de criação do pix");
}

var options = new Credentials().getOptionsJson();

JSONObject body = new JSONObject();
body.put("calendario", new JSONObject().put("expiracao", pixDurationSeconds));
body.put("valor", new JSONObject().put("original", pixChargeRequest.valor()));
body.put("chave", token);

JSONArray infoAdicionais = new JSONArray();
infoAdicionais.put(new JSONObject().put("nome", "Descrição do serviço").put("valor", pixChargeRequest.serviceDescription()));
body.put("infoAdicionais", infoAdicionais);

try {
EfiPay efi = new EfiPay(options);
JSONObject response = efi.call("pixCreateImmediateCharge", new HashMap<>(), body);
String copyAndPaste = response.getString("pixCopiaECola");
byte[] qrCode = PixGenerateQRCode.generateQRCode(copyAndPaste, 300, 300);

pixWebhookService.configPixWebhook(token);

return new PixChargeResponse(
response.get("txid").toString(),
qrCode,
copyAndPaste,
pixChargeRequest.valor(),
pixChargeRequest.serviceDescription()
);
} catch (EfiPayException e) {
logger.error("Falha ao criar cobrança pix!", e);
throw new ResponseStatusException(
HttpStatus.BAD_REQUEST,
"Falha ao criar cobrança Pix!"
);
} catch (Exception e) {
logger.error("Erro desconhecido ao criar cobrança pix!", e);
throw new ResponseStatusException(
HttpStatus.INTERNAL_SERVER_ERROR,
"Erro ao criar cobrança Pix!"
);
}
}

# assinaturas
Avatar discord do usuario neouai_leadstar

neouai_leadstar

Ver Respostas

Bom dia, estou tentando fazer uma request no endpoint:


{
"items": [
{
"name": "Meu Produto",
"value": 300,
"amount": 1
}
],
"payment": {
"credit_card": {
"customer": {
"name": "Gorbadoc Oldbuck",
"cpf": "94271564656",
"email": "[email protected]",
"birth": "1990-08-29",
"phone_number": "5144916523"
},
"payment_token": "80a1d1b775ab938172d9728572ae314a57d00f0b",
"billing_address": {
"street": "Avenida Juscelino Kubitschek",
"number": "909",
"neighborhood": "Bauxita",
"zipcode": "35400000",
"city": "Ouro Preto",
"complement": "",
"state": "MG"
}
}
}
}

Ontem a request funcionava mas hoje está retornando o erro:

{
"code": 4699998,
"error": "server_error",
"error_description": "Um ou mais parâmetros fornecidos são inválidos. must NOT have additional properties"
}

É algum problema conhecido de vocês ou eu estou enviando algo errado? Achei estranho porque ontem estava funcionando