> For the complete documentation index, see [llms.txt](https://docs.xibosignage.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.xibosignage.com/developer/integrate/openapi/daypart.md).

# DayPart

Dayparting

## Daypart Search

> Search dayparts

```json
{"openapi":"3.1.1","info":{"title":"Xibo API","version":"4.0"},"tags":[{"name":"dayPart","description":"Dayparting"}],"servers":[{"url":"/api"}],"security":[{"auth":["write:all","read:all"]}],"components":{"securitySchemes":{"auth":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"/api/authorize","tokenUrl":"/api/authorize/access_token","scopes":{"read:all":"read access","write:all":"write access"}}}}},"schemas":{"DayPart":{"properties":{"dayPartId":{"description":"The ID of this Daypart","type":"integer"},"isAlways":{"description":"A readonly flag determining whether this DayPart is always","type":"integer"},"isCustom":{"description":"A readonly flag determining whether this DayPart is custom","type":"integer"}}}}},"paths":{"/daypart":{"get":{"tags":["dayPart"],"summary":"Daypart Search","description":"Search dayparts","operationId":"dayPartSearch","parameters":[{"schema":{"type":"integer"},"name":"dayPartId","in":"query","description":"The dayPart ID to Search","required":false},{"schema":{"type":"string"},"name":"name","in":"query","description":"The name of the dayPart to Search","required":false},{"schema":{"type":"string"},"name":"embed","in":"query","description":"Embed related data such as exceptions","required":false}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DayPart"}}}}}}}}}}
```

## Daypart Add

> Add a Daypart

```json
{"openapi":"3.1.1","info":{"title":"Xibo API","version":"4.0"},"tags":[{"name":"dayPart","description":"Dayparting"}],"servers":[{"url":"/api"}],"security":[{"auth":["write:all","read:all"]}],"components":{"securitySchemes":{"auth":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"/api/authorize","tokenUrl":"/api/authorize/access_token","scopes":{"read:all":"read access","write:all":"write access"}}}}},"schemas":{"DayPart":{"properties":{"dayPartId":{"description":"The ID of this Daypart","type":"integer"},"isAlways":{"description":"A readonly flag determining whether this DayPart is always","type":"integer"},"isCustom":{"description":"A readonly flag determining whether this DayPart is custom","type":"integer"}}}}},"paths":{"/daypart":{"post":{"tags":["dayPart"],"summary":"Daypart Add","description":"Add a Daypart","operationId":"dayPartAdd","responses":{"201":{"description":"successful operation","headers":{"Location":{"description":"Location of the new record","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DayPart"}}}}},"requestBody":{"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"name":{"type":"string","description":"The Daypart Name"},"description":{"type":"string","description":"A description for the dayPart"},"startTime":{"type":"string","description":"The start time for this day part"},"endTime":{"type":"string","description":"The end time for this day part"},"exceptionDays":{"type":"array","description":"String array of exception days"},"exceptionStartTimes":{"type":"array","description":"String array of exception start times to match the exception days"},"exceptionEndTimes":{"type":"array","description":"String array of exception end times to match the exception days"}},"required":["name","startTime","endTime"]}}}}}}}}
```

## Daypart Edit

> Edit a Daypart

```json
{"openapi":"3.1.1","info":{"title":"Xibo API","version":"4.0"},"tags":[{"name":"dayPart","description":"Dayparting"}],"servers":[{"url":"/api"}],"security":[{"auth":["write:all","read:all"]}],"components":{"securitySchemes":{"auth":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"/api/authorize","tokenUrl":"/api/authorize/access_token","scopes":{"read:all":"read access","write:all":"write access"}}}}},"schemas":{"DayPart":{"properties":{"dayPartId":{"description":"The ID of this Daypart","type":"integer"},"isAlways":{"description":"A readonly flag determining whether this DayPart is always","type":"integer"},"isCustom":{"description":"A readonly flag determining whether this DayPart is custom","type":"integer"}}}}},"paths":{"/daypart/{dayPartId}":{"put":{"tags":["dayPart"],"summary":"Daypart Edit","description":"Edit a Daypart","operationId":"dayPartEdit","parameters":[{"schema":{"type":"integer"},"name":"dayPartId","in":"path","description":"The Daypart Id","required":true}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DayPart"}}}}},"requestBody":{"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"name":{"type":"string","description":"The Daypart Name"},"description":{"type":"string","description":"A description for the dayPart"},"startTime":{"type":"string","description":"The start time for this day part"},"endTime":{"type":"string","description":"The end time for this day part"},"exceptionDays":{"type":"array","description":"String array of exception days"},"exceptionStartTimes":{"type":"array","description":"String array of exception start times to match the exception days"},"exceptionEndTimes":{"type":"array","description":"String array of exception end times to match the exception days"}},"required":["name","startTime","endTime"]}}}}}}}}
```

## Delete DayPart

> Delete the provided dayPart

```json
{"openapi":"3.1.1","info":{"title":"Xibo API","version":"4.0"},"tags":[{"name":"dayPart","description":"Dayparting"}],"servers":[{"url":"/api"}],"security":[{"auth":["write:all","read:all"]}],"components":{"securitySchemes":{"auth":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"/api/authorize","tokenUrl":"/api/authorize/access_token","scopes":{"read:all":"read access","write:all":"write access"}}}}}},"paths":{"/daypart/{dayPartId}":{"delete":{"tags":["dayPart"],"summary":"Delete DayPart","description":"Delete the provided dayPart","operationId":"dayPartDelete","parameters":[{"schema":{"type":"integer"},"name":"dayPartId","in":"path","description":"The Daypart Id to Delete","required":true}],"responses":{"204":{"description":"successful operation"}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.xibosignage.com/developer/integrate/openapi/daypart.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
