Is there any documentation why does the google caldav api ignores this request.
<?xml version="1.0" encoding="UTF-8"?>
<C:calendar-query xmlns:d="DAV:"
xmlns:C="urn:ietf:params:xml:ns:caldav"
xmlns:A="http:/ /apple.com/ns/ical/">
<d:prop>
<d:getetag/>
<C:calendar-data/>
</d:prop>
<C:filter>
<C:comp-filter name="VCALENDAR">
<C:comp-filter name="VEVENT">
<C:prop-filter name="UID">
<C:text-match collation="i;octet">xxxxxxxxxxxx</C:text-match>
</C:prop-filter>
</C:comp-filter>
</C:comp-filter>
</C:filter>
</C:calendar-query>
It returns every event but it should return only the one i requested in the filter.
I can only filter the events with
<C:time-range start="20160326T230000Z" end="20160430T220000Z"/>
but everything else is just ignored.
I find another solution to get only one event by uid with caldav api google.
I use href url of the event like $href="https://apidata.googleusercontent.com/caldav/v2/IDCalendar/events/**uid.**ics
And i query with :
<?xml version="1.0" encoding="utf-8" ?>
<C:calendar-multiget xmlns="DAV:"mlns:C="urn:ietf:params:xml:ns:caldav">
<prop><getetag/><C:calendar-data/></prop>
<href>$href</href>
</C:calendar-multiget>
and i get only the event with UID :) .
Dam
but Google CalDAV supports calendar-multiget, where you can use same url pattern
https://icalendar.org/CalDAV-Access-RFC-4791/7-9-caldav-calendar-multiget-report.html
Example:
<?xml version='1.0' encoding='utf-8'?>
<C:calendar-multiget xmlns:C="urn:ietf:params:xml:ns:caldav" xmlns:CS="http://calendarserver.org/ns/" xmlns:D="DAV" xmlns:I="http://apple.com/ns/ical/">
<ns0:prop xmlns:ns0="DAV:">
<ns0:getetag/>
<C:calendar-data/>
</ns0:prop>
<ns0:href xmlns:ns0="DAV:">/caldav/v2/[calendar_id]/events/[UID]</ns0:href>
</C:calendar-multiget>
with response
<?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/[calendarID]/events/[UID]</D:href>
<D:propstat>
<D:status>HTTP/1.1 200 OK</D:status>
<D:prop>
<D:getetag>"63701474571"</D:getetag>
<caldav:calendar-data>BEGIN:VCALENDAR
.....
</caldav:calendar-data>
</D:prop>
</D:propstat>
</D:response>
</D:multistatus>
Related
I'm trying to pull a record from GeoNetwork via the following CSW (POST) request
<?xml version="1.0"?>
<csw:GetRecords xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" maxRecords="1" service="CSW" version="2.0.2" resultType="results" outputSchema="http://www.isotc211.org/2005/gmd">
<csw:Query typeNames="csw:Record">
<csw:Constraint version="1.1.0">
<Filter xmlns="http://www.opengis.net/ogc" xmlns:gml="http://www.opengis.net/gml" >
<PropertyIsEqualTo>
<PropertyName>alternateTitle</PropertyName>
<Literal>GB001503</Literal>
</PropertyIsEqualTo>
</Filter>
</csw:Constraint>
</csw:Query>
</csw:GetRecords>
The metadata record still exists and contains the correct alternateTitle value as far as I can see (snip below)
<gmd:identificationInfo>
<gmd:MD_DataIdentification>
<gmd:citation>
<gmd:CI_Citation>
<gmd:alternateTitle>
<gco:CharacterString>GB001503</gco:CharacterString>
</gmd:alternateTitle>
This previously, in runs a year ago, correctly returned one record. However, running the same query recently results in 0 records being returned. Response below:
<?xml version="1.0" encoding="UTF-8"?>
<csw:GetRecordsResponse xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.opengis.net/cat/csw/2.0.2 http://schemas.opengis.net/csw/2.0.2/CSW-discovery.xsd">
<csw:SearchStatus timestamp="2022-08-05T15:51:12.142Z" />
<csw:SearchResults numberOfRecordsMatched="0" numberOfRecordsReturned="0" elementSet="summary" nextRecord="0" />
</csw:GetRecordsResponse>
I do know that the GeoNetwork itself has been updated. Has there been a change in how GetRecords behaves in GeoNetwork? Or is there an issue with the request body?
I used the "action" option of twiML to send the recording of a call to my application and add the url and the text of call in my database
but it doesn't work
<?xml version="1.0" encoding="UTF-8"?> <Response> <Dial record="true" > +######## </Dial> <Record method="POST" action="http://myapp.com/phone_call/speech.php" timeout="10" /> </Response>
There are a number of different ways to record a call, which I assume is what you are trying to do.
You want to use the Record attribute (and associated recordingStatusCallback) of the Dial Verb. The TwiML Record verb is used for recording voice mails, as an example.
TwiML™ Voice:
Recording Incoming Twilio Voice Calls
Done :)
<?xml version="1.0" encoding="UTF-8"?>
<Response>
<Dial record="true" recordingStatusCallback="https://myapp.com/call/speech.php"
recordingStatusCallbackEvent="completed" >
+##########
</Dial>
</Response>
I have an office 365 account with the following accounts :
One main user: mainuser#company.onmicrosoft.com
Another user: someuser#company.onmicrosoft.com
someuser#company.onmicrosoft.com has shared his calendar with mainuser#company.onmicrosoft.com
Then I execute the following EWS operation (through mainuser#company.onmicrosoft.com) to get the calendar permissions set for someuser#company.onmicrosoft.com
<?xml version="1.0"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages">
<soap:Header>
<t:RequestServerVersion Version="Exchange2010"/>
</soap:Header>
<soap:Body>
<GetFolder xmlns="http://schemas.microsoft.com/exchange/services/2006/messages">
<FolderShape>
<t:BaseShape>Default</t:BaseShape>
<t:AdditionalProperties>
<t:FieldURI FieldURI="folder:PermissionSet"/>
</t:AdditionalProperties>
</FolderShape>
<m:FolderIds>
<t:DistinguishedFolderId Id="calendar">
<t:Mailbox>
<t:EmailAddress>someuser#company.onmicrosoft.com</t:EmailAddress>
</t:Mailbox>
</t:DistinguishedFolderId>
</m:FolderIds>
</GetFolder>
</soap:Body>
</soap:Envelope>
Everything is working fine, as I get a response looking like this :
<?xml version="1.0" encoding="utf-8"?>
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Header>
<h:ServerVersionInfo xmlns:h="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" MajorVersion="15" MinorVersion="20" MajorBuildNumber="56" MinorBuildNumber="13" Version="V2017_07_11"/>
</s:Header>
<s:Body>
<m:GetFolderResponse xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types">
<m:ResponseMessages>
<m:GetFolderResponseMessage ResponseClass="Success">
<m:ResponseCode>NoError</m:ResponseCode>
<m:Folders>
<t:CalendarFolder>
<t:FolderId Id="some-folder-id"/>
<t:DisplayName>Calendar</t:DisplayName>
<t:TotalCount>67</t:TotalCount>
<t:ChildFolderCount>2</t:ChildFolderCount>
<t:PermissionSet>
...
</t:PermissionSet>
</t:CalendarFolder>
</m:Folders>
</m:GetFolderResponseMessage>
</m:ResponseMessages>
</m:GetFolderResponse>
</s:Body>
</s:Envelope>
Except when someuser#company.onmicrosoft.com shares his calendars with an external contact, then when I execute the same request I suddenly get this response error :
<?xml version="1.0" encoding="utf-8"?>
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Header>
<h:ServerVersionInfo xmlns:h="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" MajorVersion="15" MinorVersion="20" MajorBuildNumber="56" MinorBuildNumber="13" Version="V2017_07_11"/>
</s:Header>
<s:Body>
<m:GetFolderResponse xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types">
<m:ResponseMessages>
<m:GetFolderResponseMessage ResponseClass="Error">
<m:MessageText>Access is denied. Check credentials and try again., Can't look up the requested Entry ID.</m:MessageText>
<m:ResponseCode>ErrorAccessDenied</m:ResponseCode>
<m:DescriptiveLinkKey>0</m:DescriptiveLinkKey>
<m:Folders/>
</m:GetFolderResponseMessage>
</m:ResponseMessages>
</m:GetFolderResponse>
</s:Body>
</s:Envelope>
I don't understand why does Office 365 return an EWS error instead of filtering the data which we should not have access to... We should be able to get the calendar permissions concerning the internal organization regardless of any external calendar sharing.
Anyone having the same issue or info about scheduled resolution ?
I am using the below XML to fetch my calendars. The response contains some of the details of my calendars but doesn't contain the default color for calendars. I also want to get the default color set for each calendar. How do I get it?
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"
xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<t:RequestServerVersion Version="Exchange2007_SP1" />
</soap:Header>
<soap:Body>
<m:FindFolder Traversal="Deep">
<m:FolderShape>
<t:BaseShape>AllProperties</t:BaseShape>
</m:FolderShape>
<m:ParentFolderIds>
<t:DistinguishedFolderId Id="calendar" />
</m:ParentFolderIds>
</m:FindFolder>
</soap:Body>
</soap:Envelope>
I'm trying to spit out XML from an array.
So it almost work except that now I'm seeing this error "Resource interpreted as document but transferred with MIME type application/xml."
When I look at the source, what is being printed is
<?xml version="1.0" encoding="UTF-8" ?>
<response>
...
</response>
<?xml version="1.0" encoding="utf-8" ?>
How do I get rid of that second
<?xml version="1.0" encoding="utf-8" ?>
Seems like that automatically gets added.
This is the url I have constructed /services/config.xml
Thanks,
Tee
Your view template should be located in the xml subfolder
/app/views/services/xml/config.ctp
The xml tag <?xml version="1.0" encoding="utf-8" ?> is then automatically rendered by the cake framework, so you should NOT have this tag in you config.ctp template. All you need to do is render your <response></response>.
Also, your services controller should render the content type HTTP header in the afterFilter:
function afterFilter()
{
$this->header('Content-Type: application/xml');
}
Good luck!