Skip to content

Latest commit

 

History

History
262 lines (169 loc) · 6.41 KB

TrxsApi.md

File metadata and controls

262 lines (169 loc) · 6.41 KB

ApiPagoFacil.TrxsApi

All URIs are relative to https://apis.pgf.cl

Method HTTP request Description
trxsIdGet GET /trxs/{id} Obtiene la informacion de la transacción exitosa, asociada a un id
trxsIdTrxNullificationGet GET /trxs/{idTrx}/nullification/
trxsIdTrxNullificationPost POST /trxs/{idTrx}/nullification
trxsIdTrxNullificationStatusGet GET /trxs/{idTrx}/nullification/status
trxsPost POST /trxs

trxsIdGet

InlineResponse2003 trxsIdGet(id)

Obtiene la informacion de la transacción exitosa, asociada a un id

Retorna información de una transacción asociada a un id, para lo que debe ingresarse en el URL el ID de la transacción a consultar. <br> El token de autorización es el obtenido a través de /Login (&quot;Inherit from parent&quot;) <br> Endpoints <br> - Producción https://apis.pgf.cl/trxs/{id} <br> - Desarrollo https://apis-dev.pgf.cl/trxs/{id}

Example

import ApiPagoFacil from 'api_pago_facil';
let defaultClient = ApiPagoFacil.ApiClient.instance;
// Configure Bearer (JWT) access token for authorization: JWTToken
let JWTToken = defaultClient.authentications['JWTToken'];
JWTToken.accessToken = "YOUR ACCESS TOKEN"

let apiInstance = new ApiPagoFacil.TrxsApi();
let id = 3.4; // Number | 
apiInstance.trxsIdGet(id, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
id Number

Return type

InlineResponse2003

Authorization

JWTToken

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

trxsIdTrxNullificationGet

InlineResponse2005 trxsIdTrxNullificationGet(idTrx)

Obtiene las anulaciones asociadas a una transacción

Example

import ApiPagoFacil from 'api_pago_facil';
let defaultClient = ApiPagoFacil.ApiClient.instance;
// Configure Bearer (JWT) access token for authorization: JWTToken
let JWTToken = defaultClient.authentications['JWTToken'];
JWTToken.accessToken = "YOUR ACCESS TOKEN"

let apiInstance = new ApiPagoFacil.TrxsApi();
let idTrx = 3.4; // Number | 
apiInstance.trxsIdTrxNullificationGet(idTrx, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
idTrx Number

Return type

InlineResponse2005

Authorization

JWTToken

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

trxsIdTrxNullificationPost

InlineResponse2004 trxsIdTrxNullificationPost(idTrx, opts)

Envía una transacción a anular

Example

import ApiPagoFacil from 'api_pago_facil';
let defaultClient = ApiPagoFacil.ApiClient.instance;
// Configure Bearer (JWT) access token for authorization: JWTToken
let JWTToken = defaultClient.authentications['JWTToken'];
JWTToken.accessToken = "YOUR ACCESS TOKEN"

let apiInstance = new ApiPagoFacil.TrxsApi();
let idTrx = 3.4; // Number | 
let opts = {
  'inlineObject1': new ApiPagoFacil.InlineObject1() // InlineObject1 | 
};
apiInstance.trxsIdTrxNullificationPost(idTrx, opts, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
idTrx Number
inlineObject1 InlineObject1 [optional]

Return type

InlineResponse2004

Authorization

JWTToken

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

trxsIdTrxNullificationStatusGet

InlineResponse2006 trxsIdTrxNullificationStatusGet(idTrx, verificationToken)

Obtiene el estado de una anulación

Example

import ApiPagoFacil from 'api_pago_facil';
let defaultClient = ApiPagoFacil.ApiClient.instance;
// Configure Bearer (JWT) access token for authorization: JWTToken
let JWTToken = defaultClient.authentications['JWTToken'];
JWTToken.accessToken = "YOUR ACCESS TOKEN"

let apiInstance = new ApiPagoFacil.TrxsApi();
let idTrx = 3.4; // Number | 
let verificationToken = "verificationToken_example"; // String | 
apiInstance.trxsIdTrxNullificationStatusGet(idTrx, verificationToken, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
idTrx Number
verificationToken String

Return type

InlineResponse2006

Authorization

JWTToken

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

trxsPost

InlineResponse2002 trxsPost(opts)

Crea una transaccion en estado pendiente. <br> La respuesta tiene distintos métodos y URLs para pago

Example

import ApiPagoFacil from 'api_pago_facil';

let apiInstance = new ApiPagoFacil.TrxsApi();
let opts = {
  'inlineObject': new ApiPagoFacil.InlineObject() // InlineObject | 
};
apiInstance.trxsPost(opts, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});

Parameters

Name Type Description Notes
inlineObject InlineObject [optional]

Return type

InlineResponse2002

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json