Posts

Post not yet marked as solved
0 Replies
624 Views
Hello,I try to get all contacts from an iCoud Account...First I run:< ?xml version="1.0" encoding="UTF-8" ?> < d:propfind xmlns:d="DAV: "> < d:prop > < d:current-user-principal/ > < /d:prop > < /d:propfind >Then I get /xxxxxxxxxxx/carddavhome/ and run:< ?xml version="1.0" encoding="UTF-8"? > < d:propfind xmlns:d="DAV:" xmlns:card="urn:ietf:params:xml:ns:carddav" > < d:prop > < card:addressbook-home-set/ > < /d:prop > < /d:propfind >This give me the URL https://pXX-contacts.icloud.com:443/xxxxxxxxxxx/carddavhome/ then I send the following request to this URL:< ?xml version="1.0" encoding="UTF-8"? > < d:propfind xmlns:d="DAV:" xmlns:card="urn:ietf:params:xml:ns:carddav" > < d:prop > < d:displayname/ > < d:resourcetype/ > < /d:prop > < /d:propfind >And I get:< ?xml version="1.0" encoding="UTF-8"? > < multistatus xmlns="DAV:" > < response > < href >/xxxxxxxxxxx/carddavhome/< /href > < propstat > < prop > < resourcetype > < collection/ > < /resourcetype > < /prop > < status >HTTP/1.1 200 OK< /status > < /propstat > < propstat > < prop > < displayname/ > < /prop > < status >HTTP/1.1 404 Not Found< /status > < /propstat > < /response > < /multistatus >If I try to run this to the the URL https://pXX-contacts.icloud.com:443/xxxxxxxxxxx/carddavhome/contacts< ?xml version="1.0" encoding="UTF-8"? > < card:addressbook-query xmlns:d="DAV:" xmlns:card="urn:ietf:params:xml:ns:carddav" > < d:prop > < d:getetag/ > < card:address-data/ > < /d:prop > < /card:addressbook-query >I get: Improperly formed XML encountered, unexpected root nodeWhat is my mistake? The first 2 queries work and give me the expected results, the 3rd one should give me a list of the addressbooks and groups and the 4th one should give me all VCards.
Posted Last updated
.