AdvancedShippingNote Web service

The AdvancedShippingNote Web service allows to download electronic delivery notes. By means of this Web services the optician software can electronically gather information about deliveries, so that the opticians don’t have to enter the data manually.

While the Web service GetAsnIDs returns a filterable list of ASNs of the authenticated optician at a certain supplier, the single ASNs can be downloaded via the service GetASN.

The feature is only available for suppliers that support the electronic delivery note.

ASN list: GetAsnIDs

The Web service GetAsnIds returns all electronic delivery notes for a certain customer at a certain supplier. It also can be searched with certain filters, that is date, clientOrderID (order number, is defined by optician software or shop), clientOrderItemID (item number in the order, is also defined by ordering software) and articleID.

Request

Productive URL:
https://www.look4optics.de/ASNService/GetAsnIDs.ashx
Test URL:
http://test.look4optics.de/ASNService/GetAsnIDs.ashx
Type:

HTTP-Service

Parameters

ticket:Ticket provided by the Look4 ID service (mandatory).
companyID:Unique company ID on Look4 Optics (see ID in URL in Look4 Optics company entry (mandatory).
filter_generationDateBegin:
 Start date for date filters, XML-compliant information necessary (e.g. 2018-02-15, optional).
filter_generationDateEnd:
 End date for date filters, XML-compliant information necessary (optional).
filter_clientOrderID:
 Specification for attribute clientOrderID in the XML-ASN (optional).
filter_clientOrderItemID:
 Specification for clientOrderItemID in the XML-ASN (optional).
filter_articleID:
 Specification for articleID in the XML-ASN (optional).

A user ID must not be sent, as the user can be identified by the Look4 ID ticket.

Example Request

GET https://www.look4optics.de/ASNService/GetAsnIDs.ashx?ticket=71095b11-7791-4106-91fb-1105cb15b53c&companyID=7856&filter_generationDateBegin=2017-03-31&filter_generationDateEnd=2017-04-15&filter_clientOrderID=1327

Response

If the request was correct, the Web service returns a XML document with all ASNs of the customer at the specified supplier.

 <GetAsnIDsResponse>
    <ASN advancedShippingNoteID="0085959257" generationDate="2017-02-15T06:10:12"/>
    <ASN advancedShippingNoteID="0086036924" generationDate="2017-02-18T06:04:54"/>
    <ASN advancedShippingNoteID="0086861661" generationDate="2017-04-12T06:10:02"/>
    <ASN advancedShippingNoteID="0086844519" generationDate="2017-04-12T06:10:00"/>
    <ASN advancedShippingNoteID="0086926454" generationDate="2017-04-15T06:05:40"/>
    <!-- ... -->
</GetAsnIDsResponse>

Successful queries respond with the status code 200 and return an XML document. Subsequent all possible reactions of the Web services are documented:

HTTP status codes

Status code ContentType Event
200 text/xml Successful return of the ID list as an XML document
400 text/plain Mandatory CGI parameter is missing
400 text/plain Wrong format of filter values (e.g. wrong date format)
400 text/plain companyID not existing
401 text/plain Ticket unknown or expired
401 text/plain Look4 ID of the client not linked with the client number at supplier

ASN download: GetAsn

The Web service GetAsn returns an electronic delivery note (ASN) as XML document. The underlying format of AdvancedShippingNote is described in the documentation for the SPECTARIS formats.

Request

Productive URL:
https://www.look4optics.de/ASNService/GetAsn.ashx
Test URL:
http://test.look4optics.de/ASNService/GetAsn.ashx
Type:

HTTP-Service

Parameters

ticket:Ticket generated by the Look4 ID service to authenticate the user (mandatory).
companyID:Unique company ID on Look4 Optics (see ID in URL in Look4 Optics company entry (mandatory).
advancedShippingNoteID:
 ID of the ASN of the GetAsnIds Web service (mandatory).

A user ID must not be sent, as the user can be identified by the Look4 ID ticket.

Example Request

https://www.look4optics.de/ASNService/GetAsn.ashx?ticket=71095b11-7791-4106-91fb-1105cb15b53c&companyID=7856&advancedShippingNoteID=0086844519

Response

If the request was correct, the GetAsn Web service returns an AdvancedShippingNote in the SPECTARIS format. You will find more information about the ASN in the documentation of the SPECTARIS format.

Example frames

<?xml version="1.0" encoding="UTF-8"?><AdvancedShippingNote xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
advancedShippingNoteID="18401321" currency="EUR" generationDate="2018-01-29T14:01:06" generatorInfo="BoDe Parity
ERP" schemaMajorVersionID="1" schemaMinorVersionID="13"
xsi:noNamespaceSchemaLocation="http://templates.look4optics.com/v_1_13/AdvancedShippingNote.xsd">
<Supplier supplierID="DE812671943" supplierName="BoDe Design Vertriebs GmbH und CoKG" >
<Addresses>
<Address addressID="1" addressType="MainAddress" city="Gemünden am Main" zip="97737" street="Hofweg 20"
isoCountryCode="DE" name="BoDe Design Vertriebs GmbH und CoKG"></Address>
</Addresses>
</Supplier>
<Client clientID="987654" clientName="Test client" >
<Addresses>
<Address addressID="2" addressType="MainAddress" city="Berlin - Spandau" zip="12345"
street="Test street 123" isoCountryCode="DE" name="Test client"></Address>
</Addresses>
</Client>
<OrderItems>
<OrderItem clientOrderID="20180118120925" clientOrderItemID="481526" articleID="SDO Marley 107" deliveryQuantity="1">
<Configuration>
<Feature templateID="InternalArticleID" selectedValue="SDO Marley 107"/>
<Feature templateID="EanCode" selectedValue="5055022609248"/>
</Configuration>
</OrderItem>
</OrderItems>
</AdvancedShippingNote>

Example contactlenses

<?xml version="1.0" encoding="UTF-8" ?><AdvancedShippingNote xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://templates.look4optics.com/v_1_13/AdvancedShippingNote.xsd" advancedShippingNoteID="2985203"
currency="EUR" generationDate="2017-12-15T06:47:13+00:00" schemaMajorVersionID="1" schemaMinorVersionID="13">
<Supplier clientSupplierID="0003501894" supplierID="DE811322707" supplierName="Bausch &amp;amp; Lomb GmbH">
<Addresses>
<Address addressID="1" addressType="MainAddress" city="Feldkirchen" clientType="Retailer"
isoCountryCode="DE" name="Bausch &amp;amp; Lomb GmbH" street="Hans-Riedl-Str. 7-9" zip="85622"></Address>
</Addresses>
</Supplier>
<Client clientID="DE21297906">
<Addresses>
<Address addressID="1" addressType="ShippingAddress" city="Faulbach" isoCountryCode="DE"
name="Distelhorst Optik &amp; Akustik GmbH" street="Bahnhofstr. 3" zip="97906"></Address>
</Addresses>
</Client>
<OrderItems>
<OrderItem advancedShippingNoteItemID="1" articleID="PV2HDT_AL" articleName="Pure Vision 2 for Astigm. 6er"
articleType="CL" clientOrderID="4524035" clientOrderItemID="16170858" deliveryDate="2017-12-15T06:47:13+00:00"
deliveryQuantity="1" orderDate="2017-12-14T00:00:00+00:00" orderTransmissionType="edi" orderedQuantity="1"
referenceName="0264509 Meier, Rechts" shippingDate="2017-12-15T00:00:00+00:00" unitOfMeasure="boxes"
orderItemType="freeOfCharge" supplierOrderID="0006345730" supplierOrderItemID="1">
<Configuration>
<Feature selectedValue="-5.25" templateID="Sphere"></Feature>
<Feature selectedValue="-0.75" templateID="Cylinder"></Feature>
<Feature selectedValue="170" templateID="AxisCylinder"></Feature>
<Feature selectedValue="8.90" templateID="RadiusBasecurve"></Feature>
<Feature selectedValue="14.50" templateID="Diameter"></Feature>
</Configuration>
</OrderItem>
<OrderItem advancedShippingNoteItemID="2" articleID="PV2HDT_AL" articleName="Pure Vision 2 for Astigm. 6er"
articleType="CL" clientOrderID="4524035" clientOrderItemID="16170859" deliveryDate="2017-12-15T06:47:13+00:00"
deliveryQuantity="1" orderDate="2017-12-14T00:00:00+00:00" orderTransmissionType="edi" orderedQuantity="1"
referenceName="0264509 Meier, Links" shippingDate="2017-12-15T00:00:00+00:00" unitOfMeasure="boxes"
orderItemType="freeOfCharge" supplierOrderID="0006345730" supplierOrderItemID="2">
<Configuration>
<Feature selectedValue="-5.25" templateID="Sphere"></Feature>
<Feature selectedValue="-1.25" templateID="Cylinder"></Feature>
<Feature selectedValue="170" templateID="AxisCylinder"></Feature>
<Feature selectedValue="8.90" templateID="RadiusBasecurve"></Feature>
<Feature selectedValue="14.50" templateID="Diameter"></Feature>
</Configuration>
</OrderItem>
</OrderItems>
</AdvancedShippingNote>

HTTP status codes

Status code ContentType Event
200 text/xml Successful return of the ID list as an XML document
400 text/plain Mandatory CGI parameter is missing
400 text/plain Unknown advancedShippingNoteID
400 text/plain companyID not existing
401 text/plain Ticket unknown or expired
401 text/plain Look4 ID of the client not linked with the client number at supplier