I'm currently implementing a WebDAV server and am totally stuck at the PROPFIND method handling. Are there any resources out there with actual examples? I have a hard time following the specification, which is imo very vague. Here's e.g. a request "Litmus" sends my server:
<?xml version="1.0" encoding="UTF-8"?>
<a:propfind xmlns:a="DAV:" xmlns="DAV:">
<b:prop xmlns:b="DAV:">
<b:getcontentlength/>
<b:getlastmodified/>
<b:displayname/>
<b:resourcetype/>
<c:foo xmlns:c="http://example.com/neon/litmus/" xmlns="http://example.com/neon/litmus/"/>
<bar/>
</b:prop>
</a:propfind>
Apparently, my response to that is not okay, since Litmus says "4. propfind_d0........... FAIL (No responses returned)":
<?xml version="1.0" encoding="UTF-8"?>
<DAV:multistatus
xmlns:DAV="DAV:">
<DAV:response>
<DAV:href>/test/litmus/</DAV:href>
<DAV:propstat>
<DAV:prop>
<DAV:getlastmodified>Fri, 30 Sep 2016 23:28:31 +0000</DAV:getlastmodified>
<DAV:displayname>litmus</DAV:displayname>
<DAV:resourcetype>
<DAV:collection></DAV:collection>
</DAV:resourcetype>
</DAV:prop>
<DAV:status>HTTP/1.1 200 OK</DAV:status>
</DAV:propstat>
<DAV:propstat>
<DAV:prop>
<DAV:getcontentlength></DAV:getcontentlength>
<a:foo
xmlns:a="http://example.com/neon/litmus/">
</a:foo>
<a:bar></a:bar>
</DAV:prop>
<DAV:status>HTTP/1.1 404 Not Found</DAV:status>
</DAV:propstat>
</DAV:response>
</DAV:multistatus>
What would be a correct response, and how can I actually find out?
Related
I'm trying to add UDID fields to PNRs using the SOAP API. There is no mention of such functionality anywhere in the docs!
So I tried using the SabreCommandLLSRQ endpoint to attach the UD fields, but I don't seem to be able to make any changes, despite receiving a * response.
I've tried the following command using the endpoint:
5.S*RL[record locator]*UD56 [some test value]
For example:
5.S*RLEPLHYN*UD56 YVRYEG
But that also leads to a * response without the PNR actually changing.
Are you sure that's the right UDID format? I've never seen a record locator prepended to a UDID before. If using the SabreCommandLLSRQ endpoint I would expect your format to look like this:
5.S*UD56 [some test value]
There are many UDID formats so I may be wrong there and I know the responses can be quirky. What response do you get in a PNR if you simply enter your format into Sabre Red?
There is also support for itin remarks in the Add Itinerary Remark (AddRemarkLLSRQ), which may be worth implementing for you as well.
I found it in the API too, it is only mentioned in one of many examples in AddRemarkRQ:
If you want it to show up on the itinerary:
<AddRemarkRQ xmlns="http://webservices.sabre.com/sabreXML/2011/10" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Version="2.1.1">
<RemarkInfo>
<Remark Type="Invoice">
<Text>
U45-111794
</Text>
</Remark>
</RemarkInfo>
</AddRemarkRQ>
If you don't want it to show up on the itinerary:
<AddRemarkRQ xmlns="http://webservices.sabre.com/sabreXML/2011/10" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Version="2.1.1">
<RemarkInfo>
<Remark Type="Invoice">
<Text>
U*45-111794
</Text>
</Remark>
</RemarkInfo>
</AddRemarkRQ>
I've tested it in both CreatePassengerNameRecordRQ and AddRemarkRQ contexts.
While playing with Google Calendar and CalDav i realized that if for a given event you modify a notification (Alarm), the event's ETag won't change.
Now, comparing ETags is essential to find out when a given event changes (in CalDav).
The request i am using to find out the ETag is
<?xml version=\"1.0\" encoding=\"utf-8\"?><d:propfind xmlns:d=\"DAV:\" xmlns:cs=\"http://calendarserver.org/ns/\"><d:prop><d:getetag /></d:prop></d:propfind>
Which would return something like
<?xml version="1.0" encoding="UTF-8"?>
<D:multistatus xmlns:D="DAV:" xmlns:caldav="urn:ietf:params:xml:ns:caldav" xmlns:cs="http://calendarserver.org/ns/" xmlns:ical="http://apple.com/ns/ical/">
<D:response xmlns:carddav="urn:ietf:params:xml:ns:carddav" xmlns:cm="http://cal.me.com/_namespace/" xmlns:md="urn:mobileme:davservices">
<D:href>/caldav/v2/myemail#gmail.com/events/</D:href>
<D:propstat>
<D:status>HTTP/1.1 200 OK</D:status>
</D:propstat>
</D:response>
<D:response xmlns:carddav="urn:ietf:params:xml:ns:carddav" xmlns:cm="http://cal.me.com/_namespace/" xmlns:md="urn:mobileme:davservices">
<D:href>/caldav/v2/myemail%40gmail.com/events/xqrjsgs1gj35cpub2nnumntm5j%40google.com.ics</D:href>
<D:propstat>
<D:status>HTTP/1.1 200 OK</D:status>
<D:prop>
<D:getetag>"63723144835"</D:getetag>
</D:prop>
</D:propstat>
</D:response>
</D:multistatus>
Now, after you go and modify the notification of that event in Google Calendar you still keep getting the same ETag:
<D:getetag>"63723144835"</D:getetag>
Is there anything else i might look for in order to find out when a notification/Alarm changes in an event? or, am i doing anything wrong?
This definitely sounds like a bug/protocol violation on the Google CalDAV implementation side:
CalDAV specifies that servers should use strong tags: https://www.rfc-editor.org/rfc/rfc4791#section-5.3.4
Strong etags correspond pretty much to bit to bit comparison: https://www.rfc-editor.org/rfc/rfc2616#section-13.3.3
Even if there were good reasons for returning a weak etag, what you get back (e.g. "63723144835") does not correspond to a weak etag syntax. Should look like "W/63723144835" (see https://www.rfc-editor.org/rfc/rfc2616#section-3.11 )
With all that said, you should really consider using WebDAV Sync ( https://www.rfc-editor.org/rfc/rfc6578 ) to monitor changes in a given calendar collection. I would be very surprised if the Google Calendar Server exposed the same issue when using sync.
I am in charge of Web Design and Marketing for the company I work for. I kind of got thrown into the role of Coding.
We use an eCommerce software to help with site structure and product information. This site uses Classic ASP to form all pages in order to make the process easier.
Well now I have been given an XML Data Feed instructions, but I have no idea where to begin. I have read some different posts, but none really give examples of what I am trying to do.
What I need to do is submit a request to "https://ec.synnex.com/SynnexXML/PriceAvailability" which is password protected and get the return xml.
Request sent to https://ec.synnex.com/SynnexXML/PriceAvailability using below xml:
<?xml version="1.0" encoding="UTF-8" ?>
<priceRequest>
<customerNo>YOUR_ID</customerNo>
<userName>USERNAME</userName>
<password>PASSWORD</password>
<skuList>
<mfgPN>PRODUCTPARTNUMBER</mfgPN>
<lineNumber>1</lineNumber>
</skuList>
</priceRequest>
and it will return the xml:
<?xml version="1.0" encoding="UTF-8" ?>
<priceResponse>
<customerNo>YOUR ACCOUNT NUMBER</customerNo>
<userName>YOUR ID</userName>
<PriceAvailabilityList>
<mfgPN>108R00645</mfgPN>
<mfgCode>13439</mfgCode>
<status>Active</status>
<description>IMAGING UNIT, PHASER 6300/6350</description>
<GlobalProductStatusCode>Active</GlobalProductStatusCode>
<price>228.48</price>
<totalQuantity>240</totalQuantity>
<AvailabilityByWarehouse>
<warehouseInfo>
<number>3</number>
<zipcode>94538</zipcode>
<city>Fremont, CA</city>
<addr>44211 Nobel Drive</addr>
</warehouseInfo>
<qty>30</qty>
</AvailabilityByWarehouse>
<AvailabilityByWarehouse>
<warehouseInfo>
<number>4</number>
<zipcode>30071</zipcode>
<city>Norcross, GA</city>
<addr>200 Best Friend Court, Suite# 250</addr>
</warehouseInfo>
<qty>27</qty>
</AvailabilityByWarehouse>
<AvailabilityByWarehouse>
<warehouseInfo>
<number>5</number>
<zipcode>75081</zipcode>
<city>Richardson, TX</city>
<addr>660 N Dorothy Drive, Suite 100</addr>
</warehouseInfo>
<qty>2</qty>
</AvailabilityByWarehouse>
<lineNumber>1</lineNumber>
</PriceAvailabilityList>
</priceResponse>
I have no idea even where to even begin with this.
Once I get the information sent and it comes back I'm sure I can assign a Dim Value and then use the call for the value in the code I already have for displaying our products. <%=whatevervalue%>
Any help would be much appreciated.
I have this annoying problem with the new Here Routing API 7.2:
If I want to use more than 2 waypoints (0 and 1) I get error as a responce from the server:
Request:
https://route.api.here.com/routing/7.2/calculateroute.xml?waypoint0=55.67395%2C12.41686&waypoint1=55.6452%2C12.52621&waypoint2=55.9552%2C12.52421&mode=fastest%3Bcar%3Btraffic:disabled%3BboatFerry:-1&language=en_US&verbosemode=0&alternatives=1&app_code=XXXXXX&app_id=XXXXXXXXXX&routeattributes=wp,sm,sc,sh,bb,lg,no
ERROR RESPONSE:
<ns2:Error xmlns:ns2="http://www.navteq.com/lbsp/Routing-Errors/1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" type="ApplicationError" subtype="NoRouteFound" xsi:type="ns2:RoutingServiceErrorType">
<Details>Error is NGEO_ERROR_INVALID_PARAMETERS</Details>
<AdditionalData key="error_code">NGEO_ERROR_INVALID_PARAMETERS</AdditionalData>
<MetaInfo>
<Timestamp>2016-02-18T15:30:21Z</Timestamp>
<MapVersion>8.30.61.154</MapVersion>
<ModuleVersion>7.2.66.0-1329</ModuleVersion>
<InterfaceVersion>2.6.21</InterfaceVersion>
</MetaInfo>
</ns2:Error>
If I take away the waypoin2 in above request it aswers ok:
Request:
https://route.api.here.com/routing/7.2/calculateroute.xml?waypoint0=55.67395%2C12.41686&waypoint1=55.6452%2C12.52621&mode=fastest%3Bcar%3Btraffic:disabled%3BboatFerry:-1&language=en_US&verbosemode=0&alternatives=1&&app_code=XXXXXXXXXX&app_id=XXXXXXXXXX&routeattributes=wp,sm,sc,sh,bb,lg,no,legs
OK RESPONSE:
<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4">
<Response>
<MetaInfo>
<Timestamp>2016-02-18T13:38:57Z</Timestamp>
<MapVersion>8.30.61.153</MapVersion>
<ModuleVersion>7.2.65.0-1222</ModuleVersion>
<InterfaceVersion>2.6.20</InterfaceVersion>
</MetaInfo>
<Route>
<Waypoint>
<LinkId>-840260969</LinkId>
<MappedPosition>
<Latitude>55.6739539</Latitude>
<Longitude>12.4166495</Longitude>
</MappedPosition>
<OriginalPosition>
<Latitude>55.6739499</Latitude>
<Longitude>12.41686</Longitude>
</OriginalPosition>
<Type>stopOver</Type>
<Spot>0.5252525</Spot>
<SideOfStreet>left</SideOfStreet>
<MappedRoadName>Hvissingevej</MappedRoadName>
<Label>Hvissingevej</Label>
<ShapeIndex>0</ShapeIndex>
</Waypoint>
<Waypoint>...</Waypoint>
<Mode>...</Mode>
<Shape>...</Shape>
<BoundingBox>
<TopLeft>
<Latitude>55.6739539</Latitude>
<Longitude>12.4158812</Longitude>
</TopLeft>
<BottomRight>
<Latitude>55.6408489</Latitude>
<Longitude>12.5263282</Longitude>
</BottomRight>
</BoundingBox>
<Leg>...</Leg>
<Summary xmlns:rtc="http://www.navteq.com/lbsp/Routing-Common/4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="rtc:RouteSummaryType">
<Distance>11768</Distance>
<TrafficTime>951</TrafficTime>
<BaseTime>951</BaseTime>
<Flags>motorway</Flags>
<Flags>builtUpArea</Flags>
<Flags>park</Flags>
<Text>
..etc
Why does it not work with more that 2 waypoints???
This looks like a big fat bug to me, but I cant find anything about it on the here.com or anywhere on the internet... :((
THIS Request with 3 waypoints used to work in the old version 6.2:
http://route.nlp.nokia.com/routing/6.2/calculateroute.xml?waypoint0=55.67395%2C12.41686&waypoint1=55.6452%2C12.52621&waypoint2=55.9552%2C12.52421&mode=fastest%3Bcar%3Btraffic:disabled%3BboatFerry:-1&language=en_US&verbosemode=0&alternatives=1&app_code=bSU31J0m--3cnUyNdSj4cw&app_id=dj92lxIBAWPAwMtNxCgm&routeattributes=wp,sm,sc,sh,bb,lg,no
OK RESPONSE:
<rtcr:CalculateRoute xmlns:rtcr="http://www.navteq.com/lbsp/Routing-CalculateRoute/4">
<Response>
<MetaInfo>...</MetaInfo>
<Route>
<RouteId>
REM8tfQAAAHRkVz-Q9ZLQGgFhqxu1ShAAAAAYETWS0AAAADAUtUoQAAAAAAAAPB_AAAAAAAA8H-XourNKMKGp1dKLwEVoKaWrTWkAAEAAABcSi8BAQAAAOk1pAABAAAAAADA_wEAAAAAAMD_ZSl--Cc6kst_SH8JSB2PGaiMIQUIAAAAlEh_CQgAAABwhiEFCAAAAAAAAP4PAAAAAAAA_s9seQ_mg7mwYJAXWCYYxLg-_P8yOgx7Z_zGqIBBluHNBoM
</RouteId>
<Waypoint>...</Waypoint>
<Waypoint>...</Waypoint>
<Waypoint>...</Waypoint>
<Mode>
<Type>fastest</Type>
<TransportModes>car</TransportModes>
<TrafficMode>disabled</TrafficMode>
<Feature weight="-1">boatFerry</Feature>
</Mode>
<Shape>...</Shape>
<BoundingBox>
<TopLeft>
<Latitude>55.9671898</Latitude>
<Longitude>12.4158802</Longitude>
</TopLeft>
<BottomRight>
<Latitude>55.6408501</Latitude>
<Longitude>12.5335598</Longitude>
</BottomRight>
</BoundingBox>
<Leg>...</Leg>
<Leg>...</Leg>
<Summary>
<Distance>62581.0</Distance>
<TrafficTime>2916.0</TrafficTime>
<BaseTime>2916.0</BaseTime>
<Flags>motorway</Flags>
</Summary>
..etc
Can please someone help me solve this?
The combination of a via point (using the waypoint2 parameter) and alternative routes (using the alternatives parameter) is not supported within the Routing API as a single request.
The Routing API reference states:
alternatives
Maximum number of alternative routes that will be calculated and
returned. Alternative routes can be unavailable, thus they are not
guaranteed to be returned. If at least one via point is used in a
route request, returning alternative routes is not supported.
So you can either find:
a single route from A to B to C or
a multiple alternate routes A to B without intermediate waypoints.
Of course if you make two separate requests you could find:
A to B with alternative routes then
B to C with alternative routes
I am attempting to pull all the General Ledger entries from QuickBooksOnline into my C# Asp.net application for a given date range. I have been able to successfully pull Bills, Checks, and JournalEntries that match the Profit and Loss Detail report I'm using for reference. However, I seem to be missing all "Deposit" types from that report. I am pulling data for Invoices and Payments but they are coming back empty for the TxnDates I'm looking for.
In case it helps I'm including the Request and Response xml logs for Invoices and Payments.
Invoice Request
Filter=TxnDate :AFTER: 2013-02-28T00:00:00-05:00 :AND: TxnDate :BEFORE: 2013-04-01T00:00:00-04:00&PageNum=1&ResultsPerPage=100
Invoice Response
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><qbo:SearchResults xmlns="http://www.intuit.com/sb/cdm/v2" xmlns:qbp="http://www.intuit.com/sb/cdm/qbopayroll/v1" xmlns:qbo="http://www.intuit.com/sb/cdm/qbo"><qbo:CdmCollections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="Invoices"/><qbo:Count>0</qbo:Count><qbo:CurrentPage>1</qbo:CurrentPage></qbo:SearchResults>
Payment Request
Filter=TxnDate :AFTER: 2013-02-28T00:00:00-05:00 :AND: TxnDate :BEFORE: 2013-04-01T00:00:00-04:00&PageNum=1&ResultsPerPage=100
Payment Response
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><qbo:SearchResults xmlns="http://www.intuit.com/sb/cdm/v2" xmlns:qbp="http://www.intuit.com/sb/cdm/qbopayroll/v1" xmlns:qbo="http://www.intuit.com/sb/cdm/qbo"><qbo:CdmCollections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="Payments"/><qbo:Count>0</qbo:Count><qbo:CurrentPage>1</qbo:CurrentPage></qbo:SearchResults>
Deposits are not the same thing as an invoice or a payment. Deposits are a separate transaction indicating a deposit of a payment, to the bank.
According to Intuit's documentation, querying for deposits is not supported by the v2 APIs.