Service


Click here for a complete list of operations.

SEGAuthorize

Autoriza un comprobante, devolviendo su CAE correspondiente

Test

The test form is only available for requests from the local machine.

SOAP 1.1

The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.

POST /wsseg/service.asmx HTTP/1.1
Host: wswhomo.afip.gov.ar
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://ar.gov.afip.dif.seg/SEGAuthorize"

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <SEGAuthorize xmlns="http://ar.gov.afip.dif.seg/">
      <Auth>
        <Token>string</Token>
        <Sign>string</Sign>
        <Cuit>long</Cuit>
      </Auth>
      <Cmp>
        <Id>long</Id>
        <Tipo_doc>short</Tipo_doc>
        <Nro_doc>long</Nro_doc>
        <Tipo_cbte>short</Tipo_cbte>
        <Punto_vta>int</Punto_vta>
        <Cbte_nro>long</Cbte_nro>
        <Imp_total>double</Imp_total>
        <Imp_tot_conc>double</Imp_tot_conc>
        <Imp_neto>double</Imp_neto>
        <Impto_liq>double</Impto_liq>
        <Impto_liq_rni>double</Impto_liq_rni>
        <Imp_op_ex>double</Imp_op_ex>
        <Imp_perc>double</Imp_perc>
        <Imp_iibb>double</Imp_iibb>
        <Imp_perc_mun>double</Imp_perc_mun>
        <Imp_internos>double</Imp_internos>
        <Imp_moneda_Id>string</Imp_moneda_Id>
        <Imp_moneda_ctz>double</Imp_moneda_ctz>
        <Imp_otrib_prov>double</Imp_otrib_prov>
        <Fecha_cbte>string</Fecha_cbte>
        <Items>
          <Item>
            <Poliza>string</Poliza>
            <Endoso>string</Endoso>
            <Ds>string</Ds>
            <Qty>double</Qty>
            <Precio_uni>double</Precio_uni>
            <Imp_bonif>double</Imp_bonif>
            <Imp_total>double</Imp_total>
            <Imp_valor_aseg>double</Imp_valor_aseg>
            <Imp_moneda_vaseg>string</Imp_moneda_vaseg>
            <Iva_id>short</Iva_id>
          </Item>
          <Item>
            <Poliza>string</Poliza>
            <Endoso>string</Endoso>
            <Ds>string</Ds>
            <Qty>double</Qty>
            <Precio_uni>double</Precio_uni>
            <Imp_bonif>double</Imp_bonif>
            <Imp_total>double</Imp_total>
            <Imp_valor_aseg>double</Imp_valor_aseg>
            <Imp_moneda_vaseg>string</Imp_moneda_vaseg>
            <Iva_id>short</Iva_id>
          </Item>
        </Items>
      </Cmp>
    </SEGAuthorize>
  </soap:Body>
</soap:Envelope>
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <SEGAuthorizeResponse xmlns="http://ar.gov.afip.dif.seg/">
      <SEGAuthorizeResult>
        <SEGResultAuth>
          <Id>long</Id>
          <Cuit>long</Cuit>
          <Cae>string</Cae>
          <Fch_venc_Cae>string</Fch_venc_Cae>
          <Fch_cbte>string</Fch_cbte>
          <Resultado>string</Resultado>
          <Reproceso>string</Reproceso>
          <Obs>string</Obs>
        </SEGResultAuth>
        <SEGErr>
          <ErrCode>int</ErrCode>
          <ErrMsg>string</ErrMsg>
        </SEGErr>
        <SEGEvents>
          <EventCode>int</EventCode>
          <EventMsg>string</EventMsg>
        </SEGEvents>
      </SEGAuthorizeResult>
    </SEGAuthorizeResponse>
  </soap:Body>
</soap:Envelope>

SOAP 1.2

The following is a sample SOAP 1.2 request and response. The placeholders shown need to be replaced with actual values.

POST /wsseg/service.asmx HTTP/1.1
Host: wswhomo.afip.gov.ar
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <SEGAuthorize xmlns="http://ar.gov.afip.dif.seg/">
      <Auth>
        <Token>string</Token>
        <Sign>string</Sign>
        <Cuit>long</Cuit>
      </Auth>
      <Cmp>
        <Id>long</Id>
        <Tipo_doc>short</Tipo_doc>
        <Nro_doc>long</Nro_doc>
        <Tipo_cbte>short</Tipo_cbte>
        <Punto_vta>int</Punto_vta>
        <Cbte_nro>long</Cbte_nro>
        <Imp_total>double</Imp_total>
        <Imp_tot_conc>double</Imp_tot_conc>
        <Imp_neto>double</Imp_neto>
        <Impto_liq>double</Impto_liq>
        <Impto_liq_rni>double</Impto_liq_rni>
        <Imp_op_ex>double</Imp_op_ex>
        <Imp_perc>double</Imp_perc>
        <Imp_iibb>double</Imp_iibb>
        <Imp_perc_mun>double</Imp_perc_mun>
        <Imp_internos>double</Imp_internos>
        <Imp_moneda_Id>string</Imp_moneda_Id>
        <Imp_moneda_ctz>double</Imp_moneda_ctz>
        <Imp_otrib_prov>double</Imp_otrib_prov>
        <Fecha_cbte>string</Fecha_cbte>
        <Items>
          <Item>
            <Poliza>string</Poliza>
            <Endoso>string</Endoso>
            <Ds>string</Ds>
            <Qty>double</Qty>
            <Precio_uni>double</Precio_uni>
            <Imp_bonif>double</Imp_bonif>
            <Imp_total>double</Imp_total>
            <Imp_valor_aseg>double</Imp_valor_aseg>
            <Imp_moneda_vaseg>string</Imp_moneda_vaseg>
            <Iva_id>short</Iva_id>
          </Item>
          <Item>
            <Poliza>string</Poliza>
            <Endoso>string</Endoso>
            <Ds>string</Ds>
            <Qty>double</Qty>
            <Precio_uni>double</Precio_uni>
            <Imp_bonif>double</Imp_bonif>
            <Imp_total>double</Imp_total>
            <Imp_valor_aseg>double</Imp_valor_aseg>
            <Imp_moneda_vaseg>string</Imp_moneda_vaseg>
            <Iva_id>short</Iva_id>
          </Item>
        </Items>
      </Cmp>
    </SEGAuthorize>
  </soap12:Body>
</soap12:Envelope>
HTTP/1.1 200 OK
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <SEGAuthorizeResponse xmlns="http://ar.gov.afip.dif.seg/">
      <SEGAuthorizeResult>
        <SEGResultAuth>
          <Id>long</Id>
          <Cuit>long</Cuit>
          <Cae>string</Cae>
          <Fch_venc_Cae>string</Fch_venc_Cae>
          <Fch_cbte>string</Fch_cbte>
          <Resultado>string</Resultado>
          <Reproceso>string</Reproceso>
          <Obs>string</Obs>
        </SEGResultAuth>
        <SEGErr>
          <ErrCode>int</ErrCode>
          <ErrMsg>string</ErrMsg>
        </SEGErr>
        <SEGEvents>
          <EventCode>int</EventCode>
          <EventMsg>string</EventMsg>
        </SEGEvents>
      </SEGAuthorizeResult>
    </SEGAuthorizeResponse>
  </soap12:Body>
</soap12:Envelope>