Calendar Web Services
Overview
Universal Controller supports the following RESTful-based web services for Calendar operations, which are listed alphabetically on this page.
- Add an Existing Custom Day to a Calendar
- Create a Calendar
- Delete a Calendar
- List Calendars
- List Local Custom Day Qualifying Dates
- List Local Custom Day Qualifying Periods
- Modify a Calendar
- Read a Calendar
- Read All Custom Days of a Calendar
- Remove a Custom Day from a Calendar
Formatting specifications for each web service, including details about parameter requirements, are provided.
Note
You can create and modify a Calendar that contains one or more global Custom Days only if the Custom Day Global Permitted Universal Controller system property is set to true.
Add an Existing Custom Day to a Calendar
Description | |
---|---|
URI | http://host_name/uc/resources/calendar/customdays |
HTTP Method | POST |
Description | Adds the specified Custom Day to the specified Calendar. |
URI Parameters | See Add an Existing Custom Day to a Calendar: URI Parameters, below. |
Example URI | http://localhost:8080/uc/resources/calendar/customdays?calendarname=test&customdayid=sfsdffsf123456dfhkjhk |
Example Response |
|
Add an Existing Custom Day to a Calendar: URI Parameters
Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|
| Unique ID for the Calendar. | Y |
| |
| Name used within the Controller to identify the Calendar. | Maximum 40 alphanumerics. | Y |
|
| Unique ID for the Custom Day. | Y |
| |
| Name used within the Controller to identify the Custom Day. | Maximum 40 alphanumerics. | Y |
|
Create a Calendar
Description | |
---|---|
URI | |
HTTP Method | POST |
Description | Creates a new Calendar. |
Example URI | http://localhost:8080/uc/resources/calendar |
Consumes Content-Type | application/xml, application/json |
Produces Content-Type | n/a |
Example Request | See Create a Calendar: Example Request, below. |
Calendar Properties | |
Custom Day Properties | |
Local Custom Day Properties | |
Example Response |
|
Create a Calendar: Example Request
XML Request | JSON Request |
---|---|
Create a Calendar: Calendar Properties
Property | UI Field Name | Description | Specifications | Required |
---|---|---|---|---|
| Business Days | Comma-separated list of days. | Valid values:
Optional: useDefaultIfBlank attribute. Boolean; Valid values: true/false.
The Read a Calendar web service will return useDefaultIfBlank only if | N |
| Description | User-defined; description for the calendar. | N | |
| n/a | Specification for whether or not to exclude related records (Custom Days, Local Custom Days) from an update, even if they are provided in the request. | Valid values: true/false (default is false). | N |
| n/a | Universal Controller release that the record was exported from. | read only | N |
| n/a | Record table information. | read only | N |
| First Day Of Week | Day that is considered the start of the week. | Valid values:
| N |
| Name | Name used within the Controller to identify this calendar. | Maximum 40 alphanumerics. | Y |
| Member of Business Services | List of Business Services: <opswiseGroups> <opswiseGroup>test</opswiseGroup> </opswiseGroups> "opswiseGroups": [ "test" ] | N | |
| n/a |
Note In XML web services, | Valid values: true/false (default is true). | N |
| n/a | System ID field in the database for this Calendar record. | Persisted only if retainSysIds is set to true. | N |
firstQuarterStart | 1st Quarter Start | To specify the start of the 1st Quarter, a day and month must be specified as shown below.
JSON
| Valid values:
| If any other Quarter is specified then this property is also required. |
secondQuarterStart | 2nd Quarter Start | To specify the start of the 1st Quarter, a day and month must be specified as shown below.
JSON
| Valid values:
| If any other Quarter is specified then this property is also required. |
thirdQuarterStart | 3rd Quarter Start | To specify the start of the 1st Quarter, a day and month must be specified as shown below.
JSON
| Valid values:
| If any other Quarter is specified then this property is also required. |
fourthQuarterStart | 4th Quarter Start | To specify the start of the 1st Quarter, a day and month must be specified as shown below.
JSON
| Valid values:
| If any other Quarter is specified then this property is also required. |
Create a Calendar: Custom Day Properties
Property | UI Field Name | Description | Specifications | Required |
---|---|---|---|---|
| Name | Name used within the Controller to identify this Custom Day. | Maximum 40 alphanumerics. | Y |
| n/a | sysId of the Calendar-to-Custom Day relationship. | N |
Create a Calendar: Local Custom Day Properties
Property | UI Field Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|---|
| Adjustment | If | Valid values:
Default is None (0). | N | |
| Adjustment Amount | If | Default is 1. | N | |
| Adjustment Type | If | Valid values:
Default is Day (1). | N | |
| Category | Category of this Local Custom Day. | Valid values:
Default is Day (1). | N | |
| Description | Description of this Local Custom Day. | N | ||
| Type | Type of this Local Custom Day. | Valid values:
Default is Single Date (0). | N | |
| Date | Specific date for this Local Custom Day | Format: yyyy-mm-dd. | Y |
|
| Dates | Multiple specific dates for this Local Custom Day. | XML <dateList> <date>2017-12-13</date> <date>2017-12-14</date> </dateList> "dateList": [ "2017-12-13", "2017-12-14" ], | Y |
|
| Day | Day of the month. | Integer; Valid values: 1-31. | Y | |
| Day Of Week | Day of the week. | Valid values:
Default is Mon (2). | Y | |
| Month | Month of the year. | Valid values:
Default is Jan (0). | Y | |
| Name | Name of this Local Custom Day. | Y | ||
| Observed Rules | If <observedRules> <observedRule> <actualDayOfWeek>Sat</actualDayOfWeek> <observedDayOfWeek>Fri</observedDayOfWeek> </observedRule> <observedRule> <actualDayOfWeek>Sun</actualDayOfWeek> <observedDayOfWeek>Mon</observedDayOfWeek> </observedRule> </observedRules> "observedRules" : [ { "actualDayOfWeek" : "Sat", "observedDayOfWeek" : "Fri" }, { "actualDayOfWeek" : "Sun", "observedDayOfWeek" : "Mon" } ] | Valid day of week values:
| N | |
| When | Occurrence of this day in the month. | Valid values:
Default is 1st (1). | Y | |
| n/a | System ID in the database for this Local Custom Day. | Persisted only if retainSysIds is set to true. | Y |
Delete a Calendar
Description | |
---|---|
URI | http://host_name/uc/resources/calendar |
HTTP Method | DELETE |
Description | Deletes the specified Calendar. |
URI Parameters | See Delete a Calendar: URI Parameters, below. |
Example URI | |
Authentication | HTTP Basic |
Example Response |
|
Delete a Calendar: URI Parameters
Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|
| Unique ID for this Calendar. | Y |
| |
| Name used within the Controller to identify this Calendar. | Maximum 40 alphanumerics. | Y |
|
List Calendars
Description | |
---|---|
URI | http://host_name/uc/resources/calendar/list |
HTTP Method | GET |
Description | Retrieves information on all Calendar. |
Example URI | http://localhost:8080/uc/resources/calendar/list |
Authentication | HTTP Basic |
Consumes Content-Type | n/a |
Produces Content-Type | application/xml, application/json |
Example Response | See List Calendars: Example Response, below. |
Calendar Properties | |
Custom Day Properties | |
Local Custom Day Properties |
List Calendars: Example Response
XML Response | JSON Response |
---|---|
List Local Custom Day Qualifying Dates
Description | |
---|---|
URI | |
HTTP Method | GET |
Description | Retrieves information on Qualifying Dates for a specific Local Custom Day. |
URI Parameters | See List Local Custom Day Qualifying Dates URI Parameters: URI Parameters, below. |
Example URI | http://localhost:8080/uc/resources/calendar/localcustomdays/qualifyingdates?customdayname=testLocalCustomDay&calendarname=testCalendar |
Authentication | HTTP Basic |
Consumes Content-Type | n/a |
Produces Content-Type | application/xml, application/json |
Example Response | See List Local Custom Day Qualifying Dates: Example Response, below. |
List Local Custom Day Qualifying Dates: URI Parameters
Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|
| Name used within the Controller to identify this Local Custom Day. | Maximum 40 alphanumerics. | Y | |
| Unique ID for this calendar. | Y |
| |
| Name used within the Controller to identify this calendar. | Maximum 40 alphanumerics. | Y |
|
List Local Custom Day Qualifying Dates: Example Response
XML Response | JSON Response |
---|---|
List Local Custom Day Qualifying Periods
Description | |
---|---|
URI | |
HTTP Method | GET |
Description | Retrieves information on Qualifying Periods for a specific Local Custom Day. |
URI Parameters | See List Local Custom Day Qualifying Periods URI Parameters: URI Parameters, below. |
Example URI | http://localhost:8080/uc/resources/calendar/localcustomdays/qualifyingperiods?customdayname=testLocalCustomDay&calendarname=testCalendar |
Authentication | HTTP Basic |
Consumes Content-Type | n/a |
Produces Content-Type | application/xml, application/json |
Example Response | See List Local Custom Day Qualifying Periods: Example Response, below. |
List Local Custom Day Qualifying Periods: Example Response
XML Response | JSON Response |
---|---|
List Custom Day Qualifying Periods: URI Parameters
Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|
| Name used within the Controller to identify this Local Custom Day. | Maximum 40 alphanumerics. | Y | |
| Unique ID for this calendar. | Y |
| |
| Name used within the Controller to identify this calendar. | Maximum 40 alphanumerics. | Y |
|
Modify a Calendar
Description | |
---|---|
URI | |
HTTP Method | PUT |
Description | Modifies the Calendar specified by the |
Example URI | http://localhost:8080/uc/resources/calendar |
Consumes Content-Type | application/xml, application/json |
Produces Content-Type | n/a |
Example Request | See Modify a Calendar: Example Request, below. |
Calendar Properties | |
Custom Day Properties | |
Local Custom Day Properties | |
Example Response |
|
Modify a Calendar: Example Request
The excludeRelated property is included in the XML as an attribute.
XML Request | JSON Request |
---|---|
Read a Calendar
Description | |
---|---|
URI | |
HTTP Method | GET |
Description | Retrieves information on a specific Calendar. |
URI Parameters | See Read a Calendar: URI Parameters, below. |
Example URI | |
Consumes Content-Type | n/a |
Produces Content-Type | application/xml, application/json |
Example Response |
|
Calendar Properties | |
Custom Day Properties | |
Local Custom Day Properties |
Read a Calendar: URI Parameters
Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|
| Unique ID for this Calendar. | Y |
| |
| Name used within the Controller to identify this Calendar. | Maximum 40 alphanumerics. | Y |
|
Read a Calendar: Example Response
The retainSysIds
and version
properties are specified as attributes in XML.
The exportReleaseLevel
and exportTable
properties are specified as attributes in XML.
XML Response | JSON Response |
---|---|
Read All Custom Days of a Calendar
Description | |
---|---|
URI | |
HTTP Method | GET |
Description | Retrieves information on all Custom Days of a specific Calendar. |
URI Parameters | See Read All Custom Days of a Calendar: URI Parameters, below. |
Example URI | http://localhost:8080/uc/resources/calendar/customdays?calendarname=test |
Consumes Content-Type | application/xml, application/json |
Produces Content-Type | n/a |
Example Response |
|
Response Properties | See Read All Custom Days of a Calendar: Response Properties, below. |
Read All Custom Days of a Calendar: URI Parameters
Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|
| Unique ID for this Calendar. | Y |
| |
| Name used within the Controller to identify this Calendar. | Maximum 40 alphanumerics. | Y |
|
Read All Custom Days of a Calendar: Example Response
The exportReleaseLevel
and exportTable
properties are specified as attributes in XML.
XML Response | JSON Response |
---|---|
Read All Custom Days of a Calendar: Properties
Property | UI Field Name | Description |
---|---|---|
| Adjustment | Adjustment for the repeating date. |
| Adjustment Amount | Amount (number of days) of the adjustment to be made. |
| Adjustment Type | Type of day on which to make the adjustment. |
| Category | Category of this Local Custom Day. |
| Description | Description of this Custom Day. |
| Type | Type of this Custom Day. |
| Date | Specific date for this Custom Day |
| Dates | Multiple specific dates for this Custom Day. |
| Day | Day of the month. |
| Day Of Week | Day of the week. |
| n/a | Universal Controller release that the record was exported from. |
| n/a | Record table information. |
| Holiday | Deprecated. Indication of whether or not this Custom Day is a holiday. |
| Month | Month of the year. |
| Name | Name of this Custom Day. |
| Period | Deprecated. Indication of whether or not this Custom Day defines a custom period of days. |
| When | Occurrence of this day in the month. |
| n/a | System ID in the database for this Custom Day. |
Remove a Custom Day from a Calendar
Description | |
---|---|
URI | http://host_name/uc/resources/calendar/customdays |
HTTP Method | DELETE |
Description | Removes the specified Custom Day from a specific Calendar. |
URI Parameters | See Remove a Custom Day from a Calendar: URI Parameters, below. |
Example URI | http://localhost:8080/uc/resources/calendar/customdays?calendarname=ExampleCalendar&customdayid=977e7539af6e450d924a92e1ad39a256 |
Authentication | HTTP Basic |
Example Response |
|
Remove a Custom Day from a Calendar: URI Parameters
Name | Description | Specifications | Required | Mutually Exclusive With |
---|---|---|---|---|
| Unique ID for the Calendar. | Y |
| |
| Name used within the Controller to identify the Calendar. | Maximum 40 alphanumerics. | Y |
|
| Unique ID for the Custom Day. | Y |
| |
| Name used within the Controller to identify the Custom Day. | Maximum 40 alphanumerics. | Y |
|