Finds upcoming event dates given one or more schedules of events and exclusions. Available parameters include `start`, `limit`, `startDate`, and `period`. There are two modes of pagination available:
* Indexed pages defined by a `start` index and a `limit`
* `period` based pagination beginning at `startDate`
Only one mode of pagination can be used at a time and the default mode is `period` with a value of `P1Y`.
To obtain the next page of results, use the `next` link in the response (if it exists) with a `POST` verb. Pass the same request body as passed to this operation (this operation is fully stateless). If there is no `next` link, the collection has been exhausted. Note that some queries may not have a terminating collection (for example, if the schedule does not have a start date). The service will update the query parameters in the link to access the next page, according to the type of pagination in use. Thait is, it will increment the `start` if initially invoked with indexed-based pagination, or it will adjust the `startDate` if initially invoked with period-based pagination. The `limit` passed to this operation will also be passed to the `next` page.
curl -X POST -H "API-Key: [[apiKey]]" "http:///dates/eventDates?start=&limit=&startDate=&period="
import { EventDatesApi } from "@apiture/dates-client-sdk";
const eventDatesApi = new EventDatesApi(configuration);
// Configure API key authorization: apiKey
var apiKey = "YOUR API KEY";
eventDatesApi.setApiKey(apiKey);
var api = new Dates.EventDatesApi.findEventDates()
var eventDatesRequest = ; // {EventDatesRequest}
var opts = {
'start': 789, // {Long} The zero-based index of the first event date item to include in this page. The default 0 denotes the beginning of the collection. If `startDate` is also provided `start` will be ignored.
'limit': 56, // {Integer} The maximum number of event dates to return in this page. If `period` is also provided, `limit` will be ignored.
'startDate': 2013-10-20, // {date} The start date of the period in which to look for events. If `period` pagination mode is being used and no `startDate` is provided, the current date will be used.
`startDate` will override `start` if both are provided.
'period': period_example // {String} The length of time used to paginate event date results. `period` will override `limit` if both are provided.
This value is an [ISO 8601 duration](https://en.wikipedia.org/wiki/ISO_8601#Durations) string of the form `P[n]Y[n]M[n]D` to specify the number of years/months/days between dates. For example, use `P7D` to paginate by weeks, `P2M` to paginate by 2 months. Time values in `period` are ignored but may be honored in the future.
};
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
eventDatesApi.findEventDates(eventDatesRequest, opts, callback);
Name |
Description |
start |
Long
(int64)
The zero-based index of the first event date item to include in this page. The default 0 denotes the beginning of the collection. If `startDate` is also provided `start` will be ignored.
|
limit |
Integer
(int32)
The maximum number of event dates to return in this page. If `period` is also provided, `limit` will be ignored.
|
startDate |
date
(date)
The start date of the period in which to look for events. If `period` pagination mode is being used and no `startDate` is provided, the current date will be used.
`startDate` will override `start` if both are provided.
|
period |
String
The length of time used to paginate event date results. `period` will override `limit` if both are provided.
This value is an [ISO 8601 duration](https://en.wikipedia.org/wiki/ISO_8601#Durations) string of the form `P[n]Y[n]M[n]D` to specify the number of years/months/days between dates. For example, use `P7D` to paginate by weeks, `P2M` to paginate by 2 months. Time values in `period` are ignored but may be honored in the future.
|