Factura Electrónica de Exportación


Solicitud
// Creamos una instancia del web service
const ws = afip.WebService("wsfex");

// Aqui deben cambiar los datos por los que correspondan. 
// Esta request de ejemplo incluye todos posibles 
// valores para llamar al metodo FEXGetCMP, puede que algun
// valor sea opcional.
const data = {
    "Auth": {
        "Token": "string",
        "Sign": "string",
        "Cuit": 1
    },
    "Cmp": {
        "Cbte_tipo": 1,
        "Punto_vta": 1,
        "Cbte_nro": 1
    }
};

try {
    // Realizamos la llamada al metodo del web service
    const response = await ws.executeRequest("FEXGetCMP", data);

    // Mostramos la respuesta por consola
    console.log(response);
catch(error){
    // En caso de error lo mostramos por consola
	console.error(error);
}
Respuesta
{
    "FEXGetCMPResult": {
        "FEXResultGet": {
            "Id": "long",
            "Fecha_cbte": "string",
            "Cbte_tipo": "short",
            "Punto_vta": "integer",
            "Cbte_nro": "long",
            "Tipo_expo": "short",
            "Permiso_existente": "string",
            "Permisos": {
                "Permiso": [
                    {
                        "Id_permiso": "string",
                        "Dst_merc": "integer"
                    }
                ]
            },
            "Dst_cmp": "short",
            "Cliente": "string",
            "Cuit_pais_cliente": "long",
            "Domicilio_cliente": "string",
            "Id_impositivo": "string",
            "Moneda_Id": "string",
            "Moneda_ctz": "decimal",
            "CanMisMonExt": "string",
            "Obs_comerciales": "string",
            "Imp_total": "decimal",
            "Obs": "string",
            "Cmps_asoc": {
                "Cmp_asoc": [
                    {
                        "Cbte_tipo": "short",
                        "Cbte_punto_vta": "integer",
                        "Cbte_nro": "long",
                        "Cbte_cuit": "long"
                    }
                ]
            },
            "Forma_pago": "string",
            "Incoterms": "string",
            "Incoterms_Ds": "string",
            "Idioma_cbte": "short",
            "Items": {
                "Item": [
                    {
                        "Pro_codigo": "string",
                        "Pro_ds": "string",
                        "Pro_qty": "decimal",
                        "Pro_umed": "integer",
                        "Pro_precio_uni": "decimal",
                        "Pro_bonificacion": "decimal",
                        "Pro_total_item": "decimal"
                    }
                ]
            },
            "Fecha_cbte_cae": "string",
            "Fch_venc_Cae": "string",
            "Cae": "string",
            "Resultado": "string",
            "Motivos_Obs": "string",
            "Opcionales": {
                "Opcional": [
                    {
                        "Id": "string",
                        "Valor": "string"
                    }
                ]
            },
            "Fecha_pago": "string",
            "Actividades": {
                "Actividad": [
                    {
                        "Id": "long"
                    }
                ]
            }
        },
        "FEXErr": {
            "ErrCode": "integer",
            "ErrMsg": "string"
        },
        "FEXEvents": {
            "EventCode": "integer",
            "EventMsg": "string"
        }
    }
}