{"swagger":"2.0","parameters":{"id":{"name":"id","in":"path","description":"The id","required":true,"type":"string"},"location_partner_id":{"name":"location_partner_id","in":"query","description":"Location partner (external) ID by which to filter results - Optional","required":false,"type":"string"},"location_mytime_id":{"name":"location_mytime_id","in":"query","description":"Location MyTime ID by which to filter results - Optional","required":false,"type":"integer"},"client_mytime_id":{"name":"client_mytime_id","in":"query","description":"Client MyTime ID by which to filter results - Optional","required":false,"default":null,"type":"integer"},"location_id":{"name":"location_id","in":"path","description":"The location's id","required":true,"type":"string"},"location_id_is_partner":{"name":"location_id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},"class_session_id":{"name":"class_session_id","in":"path","description":"The class sessions's id","required":true,"type":"integer"},"id_is_partner":{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},"Subdomain":{"name":"X-Subdomain","in":"header","description":"Merchant subdomain - Optional","required":false,"type":"string"},"page":{"name":"page","in":"query","description":"Pagination - results page number to retrieve","required":false,"type":"integer"},"Partner":{"name":"X-Partner","in":"header","description":"Partner key - Optional","required":false,"type":"string"}},"securityDefinitions":{"api_key":{"type":"apiKey","name":"X-Api-Key","in":"header"}},"security":[{"api_key":[]}],"info":{"version":"1.0.0","title":"MyTime Partners API","description":"As a MyTime Partner, you’ll be able to use restful endpoints to build an apps that helps you register customers, schedule and configure classes, appointments, and enroll customers in the events you’ve configured.\n\nFirst Steps\n---\nGetting an X-Api-Key\n--\nThe first thing you will need to make an API request is a partners API key. This is a manually generated that should be kept secure. It is used to identify each partner and validate each API request. If you don’t have a key yet, please reach out to our support team.\n\n\nSetting Header Values for Each Request\n---\nHeader: X-Api-Key\n\nFor each API request, pass your X-Api-Key in the as a header value. This should be sent by each consumer of the API. This is a 40~ characters string and is the same one you would use to login on the documentation. For using the Swagger Interactive Documentation we should use the green ‘Authorize’ button to set this header.\nE.g. Company X has the API_KEY=abcd they would send the header “X-Api-Key: abcd”\n\nHeader: Accept-Encoding\n\nIf we want to use the Swagger Interactive Documentation we should include this header on each request. This can be easily done by using a Chrome extension called 'Modify Headers’. If we don’t send this the request will be finalized correctly but the results won’t be returned correctly to the Swagger interface.\n\nHeader: X-Subdomain\n\nThis will be sent by consumers which are on their own infrastructure and have a custom subdomain. E.g. Company ABC Grooming can use abc.mytime.com thus will be sending “X-Subdomain: Abc” with every request they do through Partner APIs.\n\nHeader: X-Partner\n\n  Some of our partners require custom API responses for integration. For such partners API responses will be formatted to suit the needs of that particular integration.\n\n  Appointments and Classes\n  ----\n  If you have a business that services for groups of people for each event (eg. Yoga classes), you will use Classes, Class Sessions, Class Categories, and Attendee Types to build out your app.\n\nIf your business services one person at a time (eg. Haircuts, pet care), you will use the Appointments, and Open Times endpoints to build out your app.\n\nFormatting Dates and DateTimes\n---\nAll of the Date and Dates are formatted using the iso8601 standard.\n\nMytime ID vs Partner ID/External ID\n---\nIf you need to migrate data from your own system, it will be useful to refer to your own internal IDs when calling the Partner API instead of the ids generated in our database. If you aren’t migrating any data, there’s no need to worry about a partner_id, you can use mytime id when referencing objects.\n\nA Mytime ID, (eg. location_mytime_id, client_mytime_id) is auto generated by our MySQL Database and is always an INT or BIGINT.\n\nA Partner ID/External ID (eg. location_partner_id, client_partner_id)is an external id which can be set by an API Consumer. This can be useful in case you have your own database which you want to sync with Mytime’s database.\n\n"},"tags":[{"name":"Company","description":"Company information"},{"name":"Client","description":"A client is a customer or a patron. Use these restful endpoints to register, retrieve a list of customers, show, update, and delete. Clients can enroll in both classes and appointments."},{"name":"Children","description":"A child is a generic endpoint for and represents what a client brings to an appointment or class. Initially it was built for children but it can also represent a pet. "},{"name":"Attendee Types","description":"You can configure different Attendee Types for promotions or special attendees to a class.\n            (Eg. Employee, Promotion XYZ, Promotion ABC)."},{"name":"OpenTime","description":"Open times represent when your business has an availability for an Appointment."},{"name":"Appointment","description":"And appointment is a one on one service involving your business (eg. Haircut, Dog Wash)"},{"name":"Deal","description":"Deal Operations"},{"name":"Location","description":"A location is a distinct storefront for your business."},{"name":"Class Sessions","description":"A Class Session is a specific instance of a class. (eg. “Hot Yoga on Thursday”)\""},{"name":"Resources","description":"Resources belong to Locations and are used in Classes and Class Sessions. A Class Resource is something that a class will reserve for the duration of the class, eg. a room, sound system."},{"name":"Classes","description":"Class Operations, eg. \"Power Yoga\", \"Hot Yoga\""},{"name":"Class Categories","description":"Class Categories are used to organize different types of classes. , eg. \"Yoga\""},{"name":"Session Enrollments","description":"Session Enrollments represent the attendance of a client to a class session.\n            You need at least a class session id, a client id, and an attendee type id to make this api call. "},{"name":"External Locations","description":"Locations outside of store which can be used for scheduling classes. "},{"name":"Loyalty Program Points","description":"Loyalty program points management"},{"name":"Labels","description":"Labels that can be attached to clients"},{"name":"CustomField","description":"Custom fields defined on a company."},{"name":"StaffSchedule","description":"Staff Schedule for a location"},{"name":"Employees","description":"Employees for a company"},{"name":"Bundle Purchases","description":"Bundle purchases for clients. A bundle purchase represents a purchased package of services or products."},{"name":"Blockages","description":"Blockages are time-off / unavailability windows for a location or employee (e.g. lunch, vacation, holidays). They can be one-off or recurring."}],"host":"partners-api.mytime.com","basePath":"/api","consumes":["application/json"],"produces":["application/json"],"paths":{"/attendee_types":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Attendee type response","schema":{"type":"array","items":{"$ref":"#/definitions/AttendeeResponse"}}}},"tags":["Attendee Types"],"summary":"Returns all attendee types","description":"","produces":["application/json"]},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Attendee response","schema":{"$ref":"#/definitions/AttendeeResponse"}}},"tags":["Attendee Types"],"summary":"Creates an Attendee Type","description":"","produces":["application/json"],"parameters":[{"name":"name","in":"query","description":"name of the Attendee Type","required":true,"type":"string"}]}},"/attendee_types/{id}":{"put":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Attendee Type response","schema":{"$ref":"#/definitions/AttendeeResponse"}}},"tags":["Attendee Types"],"summary":"Updates an attendee type","description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/id"},{"name":"name","in":"query","description":"name of the Attendee Type","required":true,"type":"string"}]}},"/clients":{"get":{"summary":"Returns all clients from the system that the user has access to.","description":"\n        For each user - identified by user and password - we should have only one client per company.\n        Different MyTime Companies will have different client records for each user.\n      ","produces":["application/json"],"tags":["Client"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"page","in":"query","description":"Pagination - results page number","required":false,"type":"string"},{"name":"per_page","in":"query","description":"Pagination - number of results per per_page. Default: 20. Maximum: 20","required":false,"type":"string"},{"name":"include_children","in":"query","description":"Include the children for the client. true/false","required":false,"type":"boolean"},{"name":"include_appointments","in":"query","description":"Include appointments for the client. true/false. Max: 50","required":false,"type":"boolean"},{"name":"include_appointment_events","in":"query","description":"Include the events of the appointments for the client (dependent on \"include_appointments\"). true/false","required":false,"type":"boolean"},{"name":"include_labels","in":"query","description":"Include the labels for the client. true/false","required":false,"type":"boolean"},{"name":"include_memberships_labels","in":"query","description":"Include the memberships labels for the client. true/false","required":false,"type":"boolean"},{"name":"include_memberships","in":"query","description":"Include the memberships for the client. true/false","required":false,"type":"boolean"},{"name":"appointment_count","in":"query","description":"Include the appointments count. true/false","required":false,"type":"boolean"},{"name":"location_partner_ids","in":"query","description":"Filter clients by location","required":false,"type":"array","items":{"type":"string"}},{"name":"location_mytime_ids","in":"query","description":"Filter clients by location using mytime ids","required":false,"type":"array","items":{"type":"integer"}},{"name":"search","in":"query","description":"Filter clients by search term","required":false,"type":"string"},{"name":"client_type","in":"query","description":"Filter by client type. Allowed values: Client or Lead. Default: Client. Unsupported values default to Client.","required":false,"type":"string"},{"name":"sample_webhook","in":"query","description":"Whether or not to parse the client in the same way the webhook parses it. Used for testing purposes. true/false","required":false,"type":"boolean"}],"responses":{"200":{"description":"Clients response","schema":{"type":"object","properties":{"count":{"type":"integer"},"clients":{"type":"array","items":{"$ref":"#/definitions/Client"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"summary":"Create a new client","description":"Create a new client","produces":["application/json"],"tags":["Client"],"parameters":[{"name":"partner_id","in":"query","description":"ID","required":false,"type":"string"},{"name":"client_type","in":"query","description":"Client type","required":false,"type":"string","enum":["MyClient::Client","MyClient::Lead"]},{"$ref":"#/parameters/Subdomain"},{"name":"first_name","in":"query","description":"First name","required":true,"type":"string"},{"name":"last_name","in":"query","description":"Last name","required":false,"type":"string"},{"name":"mobile_phone","in":"query","description":"Mobile Phone","required":false,"type":"string"},{"name":"work_phone","in":"query","description":"Work Phone","required":false,"type":"string"},{"name":"email","in":"query","description":"Email","required":false,"type":"string"},{"name":"ignore_custom_required_fields","in":"query","description":"Skip the required custom fields validations","required":false,"type":"boolean"},{"name":"source_quick_add","in":"query","description":"Was the client added through a quick add?","required":false,"type":"boolean"},{"name":"can_receive_automated_emails","in":"query","description":"Can receive automated emails","required":false,"type":"boolean"},{"name":"can_receive_automated_sms","in":"query","description":"Can receive automated SMS","required":false,"type":"boolean"},{"name":"can_receive_manual_emails","in":"query","description":"Can receive manual emails","required":false,"type":"boolean"},{"name":"can_receive_manual_sms","in":"query","description":"Can receive manual sms","required":false,"type":"boolean"},{"name":"can_receive_manual_sms_confirmed_at","in":"query","description":"When was can_receive_manual_sms confirmed by double sms opt in","required":false,"type":"string","format":"date-time"},{"name":"can_receive_automated_sms_confirmed_at","in":"query","description":"When was can_receive_automated_sms confirmed by double sms opt in","required":false,"type":"string","format":"date-time"},{"name":"add_label_names","in":"query","description":"List of labels to add to the client","required":false,"type":"array","items":{"type":"string"}},{"name":"contact_preference","in":"query","description":"Contact Preference. Email = 0, Home Phone = 1, Work Phone = 2, Text Message = 3, Mobile Phone = 4","required":false,"type":"integer"},{"name":"preferred_location_partner_id","in":"query","description":"Preferred location partner id","required":false,"type":"string"},{"name":"preferred_location_mytime_id","in":"query","description":"Preferred location mytime id","required":false,"type":"string"},{"name":"associated_location_partner_ids","in":"query","description":"Associated location partner id","required":false,"type":"array","items":{"type":"string"}},{"name":"associated_location_mytime_ids","in":"query","description":"Associated location mytime id","required":false,"type":"array","items":{"type":"string"}},{"name":"addresses","in":"body","description":"Client Addresses","required":false,"schema":{"properties":{"addresses":{"type":"array","items":{"$ref":"#/definitions/CreateAddress"}}}}}],"responses":{"201":{"description":"Created","$ref":"#/definitions/Client"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/clients/{id}":{"get":{"summary":"Get client details","description":"Get client details","produces":["application/json"],"tags":["Client"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},{"name":"include_children","in":"query","description":"Include the children for the client. true/false","required":false,"type":"boolean"},{"name":"include_appointments","in":"query","description":"Include appointments for the client. true/false. Max: 50","required":false,"type":"boolean"},{"name":"include_appointment_events","in":"query","description":"Include the events of the appointments for the client (dependent on \"include_appointments\"). true/false","required":false,"type":"boolean"},{"name":"appointment_count","in":"query","description":"Include the appointments count. true/false","required":false,"type":"boolean"},{"name":"include_labels","in":"query","description":"Include the labels for the client. true/false","required":false,"type":"boolean"},{"name":"include_memberships","in":"query","description":"Include the memberships for the client. true/false","required":false,"type":"boolean"},{"name":"include_memberships_labels","in":"query","description":"Include the memberships labels for the client. true/false","required":false,"type":"boolean"}],"responses":{"200":{"description":"Updated","schema":{"type":"array","items":{"$ref":"#/definitions/Client"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"delete":{"summary":"Delete client","description":"Delete an existing client","produces":["application/json"],"tags":["Client"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"put":{"summary":"Update a client","description":"Update a client","produces":["application/json"],"tags":["Client"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Id","required":true,"type":"string"},{"name":"ignore_custom_required_fields","in":"query","description":"Skip the required custom fields validations","required":false,"type":"boolean"},{"name":"source_quick_add","in":"query","description":"Was the client added through a quick add?","required":false,"type":"boolean"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},{"name":"first_name","in":"query","description":"First name","required":false,"type":"string"},{"name":"last_name","in":"query","description":"Last name","required":false,"type":"string"},{"name":"mobile_phone","in":"query","description":"Mobile Phone","required":false,"type":"string"},{"name":"work_phone","in":"query","description":"Work Phone","required":false,"type":"string"},{"name":"email","in":"query","description":"Email","required":false,"type":"string"},{"name":"addresses","in":"body","description":"Client Addresses","required":false,"schema":{"properties":{"addresses":{"type":"array","items":{"$ref":"#/definitions/Address"}}}}},{"name":"custom_field_values","in":"body","description":"Custom field values","required":false,"schema":{"properties":{"custom_field_values":{"type":"array","items":{"$ref":"#/definitions/CustomFieldValue"}}}}},{"name":"can_receive_automated_emails","in":"query","description":"Can receive automated emails","required":false,"type":"boolean"},{"name":"can_receive_automated_sms","in":"query","description":"Can receive automated SMS","required":false,"type":"boolean"},{"name":"can_receive_manual_emails","in":"query","description":"Can receive manual emails","required":false,"type":"boolean"},{"name":"can_receive_manual_sms","in":"query","description":"Can receive manual sms","required":false,"type":"boolean"},{"name":"can_receive_manual_sms_confirmed_at","in":"query","description":"When was can_receive_manual_sms confirmed by double sms opt in","required":false,"type":"string","format":"date-time"},{"name":"can_receive_automated_sms_confirmed_at","in":"query","description":"When was can_receive_automated_sms confirmed by double sms opt in","required":false,"type":"string","format":"date-time"},{"name":"contact_preference","in":"query","description":"Contact Preference. Email = 0, Home Phone = 1, Work Phone = 2, Text Message = 3, Mobile Phone = 4","required":false,"type":"integer"},{"name":"preferred_location_partner_id","in":"query","description":"Preferred location partner id","required":false,"type":"string"},{"name":"preferred_location_mytime_id","in":"query","description":"Preferred location mytime id","required":false,"type":"integer"},{"name":"associated_location_partner_ids","in":"query","description":"Associated location partner id","required":false,"type":"array","items":{"type":"string"}},{"name":"associated_location_mytime_ids","in":"query","description":"Associated location mytime id","required":false,"type":"array","items":{"type":"string"}},{"name":"add_label_names","in":"query","description":"List of labels to add to the client","required":false,"type":"array","items":{"type":"string"}},{"name":"remove_label_names","in":"query","description":"List of labels to remove from the client","required":false,"type":"array","items":{"type":"string"}}],"responses":{"200":{"description":"Updated","schema":{"type":"array","items":{"$ref":"#/definitions/Client"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/children":{"get":{"summary":"Get all children/pets","description":"Returns all children/pets for a particular client","produces":["application/json"],"tags":["Children"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_partner_id","in":"query","description":"The client's id","required":false,"type":"string"},{"name":"client_mytime_id","in":"query","description":"The client's mytime id","required":false,"type":"integer"},{"name":"include_photo_url","in":"query","description":"When true, each child includes a photo_url field (the pet's photo URL, or null if none).","required":false,"type":"boolean"}],"responses":{"200":{"description":"Clients response","schema":{"type":"array","items":{"$ref":"#/definitions/Child"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"summary":"Create a new pet/child","description":"Create a new pet/child","produces":["application/json"],"tags":["Children"],"parameters":[{"name":"partner_id","in":"query","description":"The child's partner id","required":false,"type":"string"},{"$ref":"#/parameters/Subdomain"},{"name":"client_partner_id","in":"query","description":"The client's id","required":false,"type":"string"},{"name":"client_mytime_id","in":"query","description":"The client's mytime id","required":false,"type":"integer"},{"name":"ignore_custom_required_fields","in":"query","description":"Skip the required custom fields validations","required":false,"type":"boolean"},{"name":"source_quick_add","in":"query","description":"Was the client added through a quick add?","required":false,"type":"boolean"},{"name":"child","in":"body","description":"The child details","required":true,"schema":{"$ref":"#/definitions/Child"}}],"responses":{"200":{"description":"Created","$ref":"#/definitions/Child"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/children/{id}":{"delete":{"summary":"Delete child/pet","description":"Delete an existing child/pet","produces":["application/json"],"tags":["Children"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The child's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"put":{"summary":"Update a pet or a child","description":"Update a pet or a child","produces":["application/json"],"tags":["Children"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The child's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},{"name":"client_partner_id","in":"query","description":"The client's id","required":false,"type":"string"},{"name":"client_mytime_id","in":"query","description":"The client's mytime id","required":false,"type":"integer"},{"name":"ignore_custom_required_fields","in":"query","description":"Skip the required custom fields validations","required":false,"type":"boolean"},{"name":"source_quick_add","in":"query","description":"Was the client added through a quick add?","required":false,"type":"boolean"},{"name":"child","in":"body","description":"The child details","required":true,"schema":{"$ref":"#/definitions/Child"}}],"responses":{"200":{"description":"Updated","schema":{"type":"array","items":{"$ref":"#/definitions/Child"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/open_times":{"get":{"summary":"Get all open times","description":"Returns all open times for a variation, employee and child","produces":["application/json"],"tags":["OpenTime"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"employee_partner_id","in":"query","description":"The employee's id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"The employee's mytime id","required":false,"type":"integer"},{"name":"variations_partner_id","in":"query","description":"The variations ids","required":false,"type":"array","items":{"type":"string"}},{"name":"variations_mytime_id","in":"query","description":"The variations mytime ids","required":false,"type":"array","items":{"type":"integer"}},{"name":"child_partner_id","in":"query","description":"The child's id","required":false,"type":"string"},{"name":"child_mytime_id","in":"query","description":"The child's mytime id","required":false,"type":"integer"},{"name":"location_partner_id","in":"query","description":"The location's id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id","required":false,"type":"integer"},{"name":"date","in":"query","description":"The date for the open times e.g.: 2017-10-22","required":true,"type":"string"},{"name":"is_existing_customer","in":"query","description":"Is existing customer?","required":true,"default":false,"type":"boolean"}],"responses":{"200":{"description":"Open Times response","schema":{"type":"array","items":{"$ref":"#/definitions/OpenTime"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments":{"get":{"summary":"Get all appointments","description":"Returns all appointments from a specific location","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"location_partner_id","in":"query","description":"Filter appointments by location using the partner (external) id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"Filter appointments by location using the mytime id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"Filter appointments by Employee mytime ID","required":false,"type":"string"},{"name":"client_mytime_id","in":"query","description":"Filter appointments by Client mytime ID","required":false,"type":"string"},{"name":"for_waitlist","in":"query","description":"Return only the appointments from the waitlist","required":false,"type":"boolean"},{"name":"start_date","in":"query","description":"The start_date for the appointments. Accepts YYYY-MM-DD or ISO 8601 datetime in UTC; datetimes without an offset are assumed to be UTC. Default: Yesterday at 00:00:00 UTC. e.g.: 2017-10-22 or 2017-10-22T00:00:00","required":false,"type":"string"},{"name":"end_date","in":"query","description":"The end_date for the appointments. Accepts YYYY-MM-DD or ISO 8601 datetime in UTC; datetimes without an offset are assumed to be UTC. Default: Today at 00:00:00 UTC. e.g.: 2017-10-23 or 2017-10-23T00:00:00","required":false,"type":"string"},{"name":"created_start_date","in":"query","description":"The created_start_date for the appointments. e.g.: 2017-10-22 . created_end_date is required for this to work","required":false,"type":"string"},{"name":"created_end_date","in":"query","description":"The created_end_date for the appointments. e.g.: 2017-10-22 . created_start_date is required for this to work","required":false,"type":"string"},{"name":"include_events","in":"query","description":"Include the events for the appointment. true/false","required":false,"type":"boolean"},{"name":"include_notes","in":"query","description":"Include the notes for the appointment. true/false","required":false,"type":"boolean"},{"name":"include_custom_field_values","in":"query","description":"Include the custom field values for the appointment. true/false","required":false,"type":"boolean"},{"name":"limit","in":"query","description":"The number of results in the response. Values above 100 are capped at 100. When omitted, the default page size is applied.","required":false,"type":"integer"},{"name":"offset","in":"query","description":"The number of results to offset the response by. Eg. If the offset is 100, then the response would start at the 101st item","required":false,"type":"integer"},{"name":"sample","in":"query","description":"Returns last 10 appointments regardless of the other parameters. Used for testing purposes. true/false","required":false,"type":"boolean"},{"name":"sample_webhook","in":"query","description":"Whether or not to parse the appointment in the same way the webhook parses it. Used for testing purposes. true/false","required":false,"type":"boolean"}],"responses":{"200":{"description":"Appointment response","schema":{"type":"array","items":{"$ref":"#/definitions/Appointment"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"summary":"Create an appointment","description":"Returns the newly created appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"appointment","in":"body","description":"The appointment details. If the segments property is provided, the appointment duration will be calculated from the segments instead of the variation’s default duration. This allows custom durations for variations by explicitly defining segment durations.","required":true,"schema":{"$ref":"#/definitions/AppointmentPostBody"}},{"name":"partner_id","in":"query","description":"The appointments's id","required":false,"type":"string"},{"name":"client_partner_id","in":"query","description":"The client's id","required":false,"type":"string"},{"name":"client_mytime_id","in":"query","description":"The client's mytime id","required":false,"type":"integer"},{"name":"child_partner_id","in":"query","description":"The child's id","required":false,"type":"string"},{"name":"child_mytime_id","in":"query","description":"The child's mytime id","required":false,"type":"integer"},{"name":"location_partner_id","in":"query","description":"The location's id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id","required":false,"type":"integer"},{"name":"employee_partner_id","in":"query","description":"The employee's id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"The employee's mytime id","required":false,"type":"integer"},{"name":"begin_at","in":"query","description":"The appointment's start time. e.g 2017-10-17T10:00:00Z","required":true,"type":"string"},{"name":"end_at","in":"query","description":"The appointment's end time. e.g 2017-10-17T12:00:00Z","required":true,"type":"string"},{"name":"referrer","in":"query","description":"Referrer for appointment","required":false,"type":"string"},{"name":"address_id","in":"query","description":"Client address ID","required":false,"type":"string"},{"name":"employee_requested","in":"query","description":"Whether an employee was requested","required":false,"type":"boolean"},{"name":"check_conflicts","in":"query","description":"Whether to check for appointment conflicts or not","required":false,"type":"boolean"},{"name":"skip_bundle_purchases","in":"query","description":"Whether to skip bundle purchases when creating the appointment","required":false,"type":"boolean"}],"responses":{"200":{"description":"Appointment response","schema":{"$ref":"#/definitions/Appointment"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}":{"get":{"summary":"Get an appointment","description":"Returns the appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},{"name":"include_events","in":"query","description":"Include the events for the appointment. true/false","required":false,"type":"boolean"},{"name":"include_notes","in":"query","description":"Include the notes for the appointment. true/false","required":false,"type":"boolean"},{"name":"include_custom_field_values","in":"query","description":"Include the custom field values for the appointment. true/false","required":false,"type":"boolean"},{"name":"include_segment_employees","in":"query","description":"Include the segment_employees for each segment of the appointment. true/false","required":false,"type":"boolean"}],"responses":{"200":{"description":"Appointment response","schema":{"$ref":"#/definitions/Appointment"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"put":{"summary":"Update an appointment","description":"Returns the newly updated appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},{"name":"appointment","in":"body","description":"The appointment details","required":true,"schema":{"$ref":"#/definitions/AppointmentPostBody"}},{"name":"client_partner_id","in":"query","description":"The client's id","required":false,"type":"string"},{"name":"client_mytime_id","in":"query","description":"The client's mytime id","required":false,"type":"integer"},{"name":"child_partner_id","in":"query","description":"The child's id","required":false,"type":"string"},{"name":"child_mytime_id","in":"query","description":"The child's mytime id","required":false,"type":"integer"},{"name":"location_partner_id","in":"query","description":"The location's id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id","required":false,"type":"integer"},{"name":"employee_partner_id","in":"query","description":"The employee's id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"The employee's mytime id","required":false,"type":"integer"},{"name":"begin_at","in":"query","description":"The appointment's start time. e.g 2017-10-17T10:00:00Z","required":true,"type":"string"},{"name":"end_at","in":"query","description":"The appointment's end time. e.g 2017-10-17T12:00:00Z","required":true,"type":"string"},{"name":"address_id","in":"query","description":"Client address ID","required":false,"type":"string"}],"responses":{"200":{"description":"Appointment response","schema":{"$ref":"#/definitions/Appointment"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/cancel":{"post":{"summary":"Cancel an appointment","description":"Cancel an existing appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/completed":{"post":{"summary":"Complete an appointment","description":"Complete an existing appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/accept":{"post":{"summary":"Accept an appointment","description":"Accept an existing appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/unaccept":{"post":{"summary":"Unaccept an appointment","description":"Unaccept an existing appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/confirm":{"post":{"summary":"Confirm an appointment","description":"Confirm an existing appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/unconfirm":{"post":{"summary":"Unconfirm an appointment","description":"Unconfirm an existing appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/no_show":{"post":{"summary":"Mark an appointment as no-show","description":"Mark an existing appointment as no-show","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/showed_up":{"post":{"summary":"Mark an appointment as showed-up","description":"Mark an existing appointment as showed-up","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/client_checked_in":{"post":{"summary":"Mark an appointment as client-checked-in","description":"Mark an existing appointment as client-checked-in","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointments/{id}/cancel_waiting":{"post":{"summary":"Cancel waiting for an appointment","description":"Cancel waiting for an existing appointment","produces":["application/json"],"tags":["Appointment"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The appointments's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id / Default: true","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/reconciliations":{"get":{"summary":"Returns successful reconciliation transactions for a merchant (debits and credits).","description":"Reconciliation transactions for a merchant, including debits and credits, within a specified date range, or ever if no range is provided.","produces":["application/json"],"tags":["Reconciliations"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"start_date","in":"query","description":"The reconciliation `transfered_at` date filter start date, e.g., 2024-08-25.","required":false,"type":"date"},{"name":"end_date","in":"query","description":"The reconciliation `transfered_at` date filter end date, e.g., 2024-08-31.","required":false,"type":"date"},{"name":"page","in":"query","description":"Page requested Default: 1","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"Number of records per page Default: 10. Maximum: 100","required":false,"type":"integer"}],"responses":{"200":{"description":"Reconciliations response","schema":{"properties":{"reconciliations":{"type":"array","items":{"$ref":"#/definitions/ReconciliationList"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/royalties":{"get":{"summary":"Returns successful royalties payment transactions for a merchant.","description":"Royalties payment transactions for a merchant, including, within a specified date range, or ever if no range is provided.","produces":["application/json"],"tags":["Royalties"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"start_date","in":"query","description":"The royalty payment transaction `transfered_at` filter start date, e.g., 2024-08-25.","required":false,"type":"date"},{"name":"end_date","in":"query","description":"The royalty payment transaction `transfered_at` filter end date, e.g., 2024-08-31.","required":false,"type":"date"},{"name":"page","in":"query","description":"Page requested Default: 1","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"Number of records per page Default: 10. Maximum: 100","required":false,"type":"integer"}],"responses":{"200":{"description":"Royalties response","schema":{"properties":{"reconciliations":{"type":"array","items":{"$ref":"#/definitions/RoyaltyList"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/tickets":{"get":{"summary":"Query for tickets","description":"Returns all tickets based on query criteria","produces":["application/json"],"tags":["Tickets"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"$ref":"#/parameters/location_mytime_id"},{"name":"start_date","in":"query","description":"The ticket creation (or closed at for closed tickets query) filter start date e.g.: 2020-10-22","required":false,"type":"date"},{"name":"end_date","in":"query","description":"The ticket creation (or closed at for closed tickets query) filter end date e.g.: 2020-10-22.","required":false,"type":"date"},{"name":"closed","in":"query","description":"Return closed tickets. If false, will return all tickets.","required":false,"default":true,"type":"boolean"},{"$ref":"#/parameters/client_mytime_id"},{"$ref":"#/parameters/page"},{"name":"per_page","in":"query","description":"Pagination - number of results per per_page. Default: 20. Maximum: 20","required":false,"default":20,"type":"integer"},{"name":"sort","in":"query","description":"Default is ascending ticket id. Pass 'closed_at' (fastest, requires closed=true — the default) to order by close time, or 'closed_or_created_at' to order by closed_at falling back to created_at for tickets that are not closed. Newest first unless sort_order=asc. When sort is passed without a page parameter, the response includes an after_cursor for cursor-based pagination.","required":false,"type":"string","enum":["closed_or_created_at","closed_at"]},{"name":"sort_order","in":"query","description":"Direction for the sort parameter: 'desc' (newest first, the default) or 'asc' (oldest first). Requires sort.","required":false,"type":"string","enum":["asc","desc"]},{"name":"after_cursor","in":"query","description":"Cursor-based pagination: pass the after_cursor value returned by the previous page to fetch the next one. Requires the sort parameter. When present, page is ignored. The response omits after_cursor on the last page. Recommended for sync integrations over page-based pagination — tickets closed while paging are never skipped. The cursor is a timestamp (start with a sorted request and no page parameter to get the first cursor), advances in the sort_order direction, and a page boundary may repeat a ticket (dedupe by id).","required":false,"type":"string"}],"responses":{"200":{"description":"Tickets response","schema":{"properties":{"tickets":{"type":"array","items":{"$ref":"#/definitions/TicketObject"}},"count":{"type":"integer"},"after_cursor":{"type":"string"}},"type":"object"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/tickets/{id}":{"get":{"summary":"Get ticket details","description":"Get ticket details","produces":["application/json"],"tags":["Tickets"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"id","in":"path","description":"id of the specific ticket","required":true,"type":"integer"}],"responses":{"200":{"description":"Ticket response","schema":{"type":"array","items":{"$ref":"#/definitions/TicketObject"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"put":{"summary":"Add line items to an open ticket","description":"Appends line items (sku_item, misc_item) to an open POS ticket. sku_item entries are priced server-side; misc_item amounts are caller-set. Only open tickets may be edited.","produces":["application/json"],"tags":["Tickets"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"id","in":"path","description":"id of the specific ticket","required":true,"type":"integer"},{"name":"body","in":"body","description":"The line items to append to the ticket","required":true,"schema":{"$ref":"#/definitions/TicketUpdateBody"}}],"responses":{"200":{"description":"Updated ticket response","schema":{"properties":{"ticket":{"$ref":"#/definitions/TicketObject"}}}},"400":{"description":"Bad Request","schema":{"$ref":"#/definitions/ErrorModel"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Ticket not found, not the company's ticket, or editing not enabled","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/tickets/item_types":{"get":{"summary":"Returns all item types available for this company.","description":"Ticket item types defined for a this company, like Membership Purchase, Gift Card, etc.","produces":["application/json"],"tags":["Tickets"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}],"responses":{"200":{"description":"Ticket Item Types response","schema":{"properties":{"item_types":{"type":"array","items":{"$ref":"#/definitions/TicketItemTypeList"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/tickets/payment_types":{"get":{"summary":"Returns all payment types available for a company.","description":"Ticket payment types defined for a given company, like Cash, check, etc","produces":["application/json"],"tags":["Tickets"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}],"responses":{"200":{"description":"Ticket Payment Types response","schema":{"properties":{"payment_item_types":{"type":"array","items":{"$ref":"#/definitions/TicketPaymentTypeList"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/tickets/refunds":{"get":{"summary":"Returns all refunds requested.","description":"Refunds for a given company, within the time frame specified and paginated.","produces":["application/json"],"tags":["Tickets"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"start_date","in":"query","description":"The ticket creation filter start date e.g.: 2020-10-22","required":false,"type":"string"},{"name":"end_date","in":"query","description":"The ticket creation filter end date e.g.: 2020-10-22","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id","required":false,"type":"integer"},{"name":"page","in":"query","description":"Page number to return, starting at 1","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"row number to count as one page. Default: 20","required":false,"type":"integer"}],"responses":{"200":{"description":"Refund list response","schema":{"properties":{"refunds":{"type":"array","items":{"$ref":"#/definitions/TicketObject"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/tickets/journals":{"get":{"summary":"Returns all journals requested.","description":"Journals for a given company, within the time frame specified and paginated.","produces":["application/json"],"tags":["Tickets"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"start_date","in":"query","description":"The ticket creation filter start date e.g.: 2020-10-22","required":false,"type":"string"},{"name":"end_date","in":"query","description":"The ticket creation filter end date e.g.: 2020-10-22","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id","required":false,"type":"integer"},{"name":"page","in":"query","description":"Page number to return, starting at 1","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"row number to count as one page. Default: 20","required":false,"type":"integer"},{"name":"is_completed","in":"query","description":"Set this value to `true` if the journal query for the day has been completed. Default: `false`","required":false,"type":"string"}],"responses":{"200":{"description":"Journals list response","schema":{"properties":{"journals":{"type":"array","items":{"$ref":"#/definitions/TicketObject"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/services":{"get":{"summary":"Get all services","description":"Returns all service categories for the company","produces":["application/json"],"tags":["Service"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}],"responses":{"200":{"description":"Services response","schema":{"type":"array","items":{"$ref":"#/definitions/Service"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/deals":{"get":{"summary":"Returns all deals from a specific location.","description":"A deal is a service that a company can provide. Each deal can have multiple variations (i.e. service variations). E.g. Company 'ABC Haircut' can have a deal 'Woman Haircut' and two variations - 'Woman Haircut for Long Hair' and 'Woman Haircut for Short Hair' Note: Prices are set per variation not per deal.","produces":["application/json"],"tags":["Deal"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"location_partner_id","in":"query","description":"Filter deals by location using the partner (external) id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"Filter deals by location using the mytime id","required":false,"type":"string"}],"responses":{"200":{"description":"Deals response","schema":{"type":"array","items":{"$ref":"#/definitions/Deal"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/variations":{"get":{"summary":"Returns all variations and its respective pricings for a specific location.","description":"Note: Variations are defined by location through pricing. Deleted variations do not belong to any location","produces":["application/json"],"tags":["Variations"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"location_partner_id","in":"query","description":"Filter variations by location using the partner (external) id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"Filter variations by location using the mytime id","required":false,"type":"string"},{"name":"with_deleted","in":"query","description":"Return deleted variations.","required":false,"type":"boolean"}],"responses":{"200":{"description":"variations response","schema":{"type":"array","items":{"$ref":"#/definitions/Variations"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/locations":{"get":{"summary":"Get all locations","description":"Returns all locations from a specific location","produces":["application/json"],"tags":["Location"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"sample_webhook","in":"query","description":"Whether or not to parse the location in the same way the webhook parses it. Used for testing purposes. true/false","required":false,"type":"boolean"}],"responses":{"200":{"description":"Locations response","schema":{"type":"array","items":{"$ref":"#/definitions/Location"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Location response","schema":{"$ref":"#/definitions/LocationResponse"}}},"tags":["Location"],"summary":"Creates an Location","description":"","produces":["application/json"],"parameters":[{"name":"company_id","type":"string","required":false,"in":"query"},{"name":"street_address","type":"string","required":true,"in":"query"},{"name":"street_address_2","type":"string","required":false,"in":"query"},{"name":"city","type":"string","required":true,"in":"query"},{"name":"lat","type":"string","required":false,"in":"query"},{"name":"lng","type":"string","required":false,"in":"query"},{"name":"time_zone","type":"string","required":false,"in":"query"},{"name":"state","type":"string","required":true,"in":"query"},{"name":"zip_code","type":"string","required":true,"in":"query"},{"name":"phone_number","type":"string","required":false,"in":"query"},{"name":"mobile_number","type":"string","required":false,"in":"query"},{"name":"partner_id","type":"string","required":false,"in":"query"},{"name":"mytime_id","type":"string","required":false,"in":"query"},{"name":"country","type":"string","required":false,"in":"query"},{"name":"nickname","type":"string","required":false,"in":"query"},{"name":"external_online_booking_url","type":"string","required":false,"in":"query"}]}},"/locations/{id}":{"get":{"summary":"Get location details","description":"Get location details","produces":["application/json"],"tags":["Location"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"}],"responses":{"200":{"description":"Locations response","schema":{"type":"array","items":{"$ref":"#/definitions/Location"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/class_sessions":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"ClassSession response","schema":{"type":"array","items":{"$ref":"#/definitions/ClassSessionResponse"}}}},"parameters":[{"$ref":"#/parameters/location_partner_id"},{"$ref":"#/parameters/location_mytime_id"},{"$ref":"#/parameters/Subdomain"},{"name":"start_date","in":"query","description":"The start_date for the class sessions. Default: Yesterday. e.g.: 2017-10-22","required":false,"type":"string"},{"name":"end_date","in":"query","description":"The end_date for the class sessions. Default: Today. e.g.: 2017-10-22","required":false,"type":"string"},{"name":"include_events","in":"query","description":"Include the events for the class sessions. true/false","required":false,"type":"boolean"}],"summary":"Get all class sessions","description":"Returns all class sessions from a specific location","produces":["application/json"],"tags":["Class Sessions"]},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"ClassSession response","schema":{"$ref":"#/definitions/ClassSessionResponse"}}},"summary":"Create a class session","description":"Returns the newly created class sessions","produces":["application/json"],"tags":["Class Sessions"],"parameters":[{"name":"class_session","in":"body","description":"Class Session  object","required":true,"schema":{"$ref":"#/definitions/SessionRequest"}},{"$ref":"#/parameters/location_id"},{"$ref":"#/parameters/location_id_is_partner"},{"name":"segments","in":"query","description":"returns segments","type":"boolean"},{"name":"location","in":"query","description":"returns location","type":"boolean"},{"name":"external_location","in":"query","description":"returns external_location","type":"boolean"},{"name":"employee","in":"query","description":"returns employee","type":"boolean"},{"name":"resource","in":"query","description":"returns resource","type":"boolean"},{"name":"class_name","in":"query","description":"returns class_name","type":"boolean"},{"name":"class","in":"query","description":"returns class","type":"boolean"},{"name":"category","in":"query","description":"returns category","type":"boolean"},{"name":"class_setting","in":"query","description":"returns class_setting","type":"boolean"},{"name":"session_enrollments","in":"query","description":"returns session_enrollments","type":"boolean"},{"name":"session_events","in":"query","description":"returns session_events","type":"boolean"},{"name":"client","in":"query","description":"returns client","type":"boolean"},{"name":"child","in":"query","description":"returns child","type":"boolean"},{"name":"custom_field_values","in":"query","description":"returns custom_field_values","type":"boolean"},{"name":"display_color_ids","in":"query","description":"returns display_color_ids","type":"boolean"},{"name":"notes","in":"query","description":"returns notes","type":"boolean"},{"name":"ticket_summary","in":"query","description":"returns ticket_summary","type":"boolean"},{"name":"recurring_session","in":"query","description":"returns recurring_session","type":"boolean"},{"name":"session_attendees","in":"query","description":"returns session_attendees","type":"boolean"},{"name":"attendee","in":"query","description":"returns attendee","type":"boolean"},{"name":"num_enrolled_per_attendee","in":"query","description":"returns num_enrolled_per_attendee","type":"boolean"},{"name":"num_unpaid","in":"query","description":"returns num_unpaid","type":"boolean"},{"name":"total_capacity","in":"query","description":"returns total_capacity","type":"boolean"}]}},"/class_sessions/{id}":{"put":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"ClassSession response","schema":{"$ref":"#/definitions/ClassSessionResponse"}}},"summary":"Update a class session","description":"Returns the newly updated class sessions","produces":["application/json"],"tags":["Class Sessions"],"parameters":[{"$ref":"#/parameters/id"},{"name":"class_session","in":"body","description":"Class Session  object","required":true,"schema":{"$ref":"#/definitions/SessionRequest"}},{"$ref":"#/parameters/location_id"},{"$ref":"#/parameters/location_id_is_partner"},{"name":"segments","in":"query","description":"returns segments","type":"boolean"},{"name":"location","in":"query","description":"returns location","type":"boolean"},{"name":"external_location","in":"query","description":"returns external_location","type":"boolean"},{"name":"employee","in":"query","description":"returns employee","type":"boolean"},{"name":"resource","in":"query","description":"returns resource","type":"boolean"},{"name":"class_name","in":"query","description":"returns class_name","type":"boolean"},{"name":"class","in":"query","description":"returns class","type":"boolean"},{"name":"category","in":"query","description":"returns category","type":"boolean"},{"name":"class_setting","in":"query","description":"returns class_setting","type":"boolean"},{"name":"session_enrollments","in":"query","description":"returns session_enrollments","type":"boolean"},{"name":"session_events","in":"query","description":"returns session_events","type":"boolean"},{"name":"client","in":"query","description":"returns client","type":"boolean"},{"name":"child","in":"query","description":"returns child","type":"boolean"},{"name":"custom_field_values","in":"query","description":"returns custom_field_values","type":"boolean"},{"name":"display_color_ids","in":"query","description":"returns display_color_ids","type":"boolean"},{"name":"notes","in":"query","description":"returns notes","type":"boolean"},{"name":"ticket_summary","in":"query","description":"returns ticket_summary","type":"boolean"},{"name":"recurring_session","in":"query","description":"returns recurring_session","type":"boolean"},{"name":"session_attendees","in":"query","description":"returns session_attendees","type":"boolean"},{"name":"attendee","in":"query","description":"returns attendee","type":"boolean"},{"name":"num_enrolled_per_attendee","in":"query","description":"returns num_enrolled_per_attendee","type":"boolean"},{"name":"num_unpaid","in":"query","description":"returns num_unpaid","type":"boolean"},{"name":"total_capacity","in":"query","description":"returns total_capacity","type":"boolean"}]},"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"ClassSession response","schema":{"$ref":"#/definitions/ClassSessionResponse"}}},"summary":"Get a class session","description":"Returns the class sessions","produces":["application/json"],"tags":["Class Sessions"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/id"},{"$ref":"#/parameters/location_id"},{"$ref":"#/parameters/id_is_partner"},{"$ref":"#/parameters/location_mytime_id"}]}},"/class_sessions/{id}/cancel":{"delete":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"204":{"description":"Deleted","schema":{"$ref":"#/definitions/ClassSessionResponse"}}},"summary":"Cancel a class session","description":"Cancel an existing class sessions","produces":["application/json"],"tags":["Class Sessions"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/id_is_partner"},{"$ref":"#/parameters/id"}]}},"/classes":{"get":{"tags":["Classes"],"summary":"Returns all classes","description":"","produces":["application/json"],"parameters":[{"name":"category","in":"query","description":"returns category","type":"boolean"},{"name":"class_settings","in":"query","description":"returns class_settings","type":"boolean"},{"name":"class_setting_attendees","in":"query","description":"returns class_setting_attendees","type":"boolean"},{"name":"segment_templates","in":"query","description":"returns segment_templates","type":"boolean"},{"name":"class_setting_locations","in":"query","description":"returns class_setting_locations","type":"boolean"},{"name":"class_setting_location_groups","in":"query","description":"returns class_setting_location_groups","type":"boolean"},{"name":"class_setting_location_ids","in":"query","description":"returns class_setting_location_ids","type":"boolean"},{"name":"class_setting_location_group_ids","in":"query","description":"returns class_setting_location_group_ids","type":"boolean"},{"name":"attendee","in":"query","description":"returns attendee","type":"boolean"},{"name":"location","in":"query","description":"returns location","type":"boolean"},{"name":"location_group","in":"query","description":"returns location_group","type":"boolean"},{"name":"requirement_employees","in":"query","description":"returns requirement_employees","type":"boolean"},{"name":"requirement_employee_ids","in":"query","description":"returns requirement_employee_ids","type":"boolean"},{"name":"requirement_resources","in":"query","description":"returns requirement_resources","type":"boolean"},{"name":"requirement_resource_ids","in":"query","description":"returns requirement_resource_ids","type":"boolean"},{"name":"requirements","in":"query","description":"returns requirements","type":"boolean"}],"responses":{"200":{"description":"Classes response","schema":{"type":"array","items":{"$ref":"#/definitions/ClassResponse"}}}}},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Class response","schema":{"$ref":"#/definitions/ClassResponse"}}},"tags":["Classes"],"summary":"Creates a class","description":"","produces":["application/json"],"parameters":[{"name":"class","in":"body","description":"Class name","required":true,"schema":{"$ref":"#/definitions/ClassRequest"}},{"name":"category","in":"query","description":"returns category","type":"boolean"},{"name":"class_settings","in":"query","description":"returns class_settings","type":"boolean"},{"name":"class_setting_attendees","in":"query","description":"returns class_setting_attendees","type":"boolean"},{"name":"segment_templates","in":"query","description":"returns segment_templates","type":"boolean"},{"name":"class_setting_locations","in":"query","description":"returns class_setting_locations","type":"boolean"},{"name":"class_setting_location_groups","in":"query","description":"returns class_setting_location_groups","type":"boolean"},{"name":"class_setting_location_ids","in":"query","description":"returns class_setting_location_ids","type":"boolean"},{"name":"class_setting_location_group_ids","in":"query","description":"returns class_setting_location_group_ids","type":"boolean"},{"name":"attendee","in":"query","description":"returns attendee","type":"boolean"},{"name":"location","in":"query","description":"returns location","type":"boolean"},{"name":"location_group","in":"query","description":"returns location_group","type":"boolean"},{"name":"requirement_employees","in":"query","description":"returns requirement_employees","type":"boolean"},{"name":"requirement_employee_ids","in":"query","description":"returns requirement_employee_ids","type":"boolean"},{"name":"requirement_resources","in":"query","description":"returns requirement_resources","type":"boolean"},{"name":"requirement_resource_ids","in":"query","description":"returns requirement_resource_ids","type":"boolean"},{"name":"requirements","in":"query","description":"returns requirements","type":"boolean"}]}},"/classes/{id}":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Class response","schema":{"$ref":"#/definitions/ClassResponse"}}},"tags":["Classes"],"summary":"Returns a class by id","description":"","parameters":[{"$ref":"#/parameters/id"},{"$ref":"#/parameters/id_is_partner"},{"name":"category","in":"query","description":"returns category","type":"boolean"},{"name":"class_settings","in":"query","description":"returns class_settings","type":"boolean"},{"name":"class_setting_attendees","in":"query","description":"returns class_setting_attendees","type":"boolean"},{"name":"segment_templates","in":"query","description":"returns segment_templates","type":"boolean"},{"name":"class_setting_locations","in":"query","description":"returns class_setting_locations","type":"boolean"},{"name":"class_setting_location_groups","in":"query","description":"returns class_setting_location_groups","type":"boolean"},{"name":"class_setting_location_ids","in":"query","description":"returns class_setting_location_ids","type":"boolean"},{"name":"class_setting_location_group_ids","in":"query","description":"returns class_setting_location_group_ids","type":"boolean"},{"name":"attendee","in":"query","description":"returns attendee","type":"boolean"},{"name":"location","in":"query","description":"returns location","type":"boolean"},{"name":"location_group","in":"query","description":"returns location_group","type":"boolean"},{"name":"requirement_employees","in":"query","description":"returns requirement_employees","type":"boolean"},{"name":"requirement_employee_ids","in":"query","description":"returns requirement_employee_ids","type":"boolean"},{"name":"requirement_resources","in":"query","description":"returns requirement_resources","type":"boolean"},{"name":"requirement_resource_ids","in":"query","description":"returns requirement_resource_ids","type":"boolean"},{"name":"requirements","in":"query","description":"returns requirements","type":"boolean"}],"produces":["application/json"]},"put":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Class response","schema":{"$ref":"#/definitions/ClassResponse"}}},"tags":["Classes"],"summary":"Updates a class","description":"","produces":["application/json"],"parameters":[{"name":"class","in":"body","description":"Class","required":true,"schema":{"$ref":"#/definitions/ClassRequest"}},{"$ref":"#/parameters/id_is_partner"},{"$ref":"#/parameters/id"},{"name":"category","in":"query","description":"returns category","type":"boolean"},{"name":"class_settings","in":"query","description":"returns class_settings","type":"boolean"},{"name":"class_setting_attendees","in":"query","description":"returns class_setting_attendees","type":"boolean"},{"name":"segment_templates","in":"query","description":"returns segment_templates","type":"boolean"},{"name":"class_setting_locations","in":"query","description":"returns class_setting_locations","type":"boolean"},{"name":"class_setting_location_groups","in":"query","description":"returns class_setting_location_groups","type":"boolean"},{"name":"class_setting_location_ids","in":"query","description":"returns class_setting_location_ids","type":"boolean"},{"name":"class_setting_location_group_ids","in":"query","description":"returns class_setting_location_group_ids","type":"boolean"},{"name":"attendee","in":"query","description":"returns attendee","type":"boolean"},{"name":"location","in":"query","description":"returns location","type":"boolean"},{"name":"location_group","in":"query","description":"returns location_group","type":"boolean"},{"name":"requirement_employees","in":"query","description":"returns requirement_employees","type":"boolean"},{"name":"requirement_employee_ids","in":"query","description":"returns requirement_employee_ids","type":"boolean"},{"name":"requirement_resources","in":"query","description":"returns requirement_resources","type":"boolean"},{"name":"requirement_resource_ids","in":"query","description":"returns requirement_resource_ids","type":"boolean"},{"name":"requirements","in":"query","description":"returns requirements","type":"boolean"}]},"delete":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Success response","schema":{"type":"object"}}},"tags":["Classes"],"summary":"Deletes a class and its class settings by id","description":"","parameters":[{"$ref":"#/parameters/id"},{"$ref":"#/parameters/id_is_partner"}],"produces":["application/json"]}},"/session_enrollments":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Session Enrollment response","schema":{"type":"array","items":{"$ref":"#/definitions/SessionEnrollmentResponse"}}}},"summary":"Get all session enrollments","description":"Returns all session enrollments from a specific location","produces":["application/json"],"tags":["Session Enrollments"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"class_session_partner_id","in":"query","description":"Filter session enrollments by class session using the partner (external) id","required":false,"type":"string"},{"name":"class_session_mytime_id","in":"query","description":"Filter session enrollments by class session using the mytime id","required":false,"type":"string"},{"name":"client_partner_id","in":"query","description":"Filter session enrollments by class session using the partner (external) id","required":false,"type":"string"},{"name":"client_mytime_id","in":"query","description":"Filter session enrollments by class session using the mytime id","required":false,"type":"string"}]},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"SessionEnrollment response","schema":{"$ref":"#/definitions/SessionEnrollmentResponse"}}},"summary":"Create a session enrollment","description":"Returns the newly created session enrollments","produces":["application/json"],"tags":["Session Enrollments"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"class_session_partner_id","in":"query","description":"Class session partner (external) id","type":"string"},{"name":"class_session_mytime_id","in":"query","description":"Class session mytime id","type":"string"},{"name":"client_partner_id","in":"query","description":"The client's id","type":"string"},{"name":"client_mytime_id","in":"query","description":"The client's mytime id","type":"integer"},{"name":"child_partner_id","in":"query","description":"The child's id","required":false,"type":"string"},{"name":"child_mytime_id","in":"query","description":"The child's mytime id","required":false,"type":"integer"},{"name":"amount","in":"query","description":"The amount paid by the client","required":false,"type":"integer"},{"name":"attendee_type_id","in":"query","description":"The attendee's mytime id","required":true,"type":"integer"}]}},"/session_enrollments/{id}":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"SessionEnrollment response","schema":{"type":"object","$ref":"#/definitions/SessionEnrollmentResponse"}}},"summary":"Get a session enrollments","description":"Returns the session enrollments","produces":["application/json"],"tags":["Session Enrollments"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The session enrollments's id","required":true,"type":"string"},{"$ref":"#/parameters/id_is_partner"}]},"put":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"SessionEnrollment response","schema":{"$ref":"#/definitions/SessionEnrollmentResponse"}}},"summary":"Update a session enrollments","description":"Returns the newly updated session enrollments","produces":["application/json"],"tags":["Session Enrollments"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The session enrollments's id","required":true,"type":"string"},{"$ref":"#/parameters/id_is_partner"},{"name":"amount","in":"query","description":"The amount paid by the client","required":false,"type":"integer"},{"name":"attendee_type_id","in":"query","description":"The attendee's mytime id","required":false,"type":"integer"}]}},"/session_enrollments/{id}/cancel":{"delete":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"204":{"description":"Deleted"}},"summary":"Cancel a session enrollments","description":"Cancel an existing session enrollments","produces":["application/json"],"tags":["Session Enrollments"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The session enrollments's id","required":true,"type":"string"},{"$ref":"#/parameters/id_is_partner"}]}},"/session_enrollments/{id}/confirm":{"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"204":{"description":"SessionEnrollment response","schema":{"type":"object","$ref":"#/definitions/SessionEnrollment"}}},"summary":"Confirm a session enrollment","description":"Confirm an existing session enrollment","produces":["application/json"],"tags":["Session Enrollments"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The session enrollments's id","required":true,"type":"string"},{"$ref":"#/parameters/id_is_partner"}]}},"/session_enrollments/{id}/unconfirm":{"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"SessionEnrollment response","schema":{"type":"object","$ref":"#/definitions/SessionEnrollmentResponse"}}},"summary":"Unconfirm a session enrollment","description":"Unconfirm an existing session enrollment","produces":["application/json"],"tags":["Session Enrollments"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The session enrollments's id","required":true,"type":"string"},{"$ref":"#/parameters/id_is_partner"}]}},"/resources":{"get":{"summary":"Returns all classes","tags":["Resources"],"description":"","produces":["application/json"],"parameters":[{"name":"resource_id","in":"query","description":"Resource id","type":"integer"},{"name":"location_mytime_ids","in":"query","description":"Location id","type":"integer"},{"name":"location_partner_ids","in":"query","description":"Location id","type":"integer"}],"responses":{"200":{"description":"Classes response","schema":{"type":"array","items":{"$ref":"#/definitions/ResourceResponse"}}}}},"post":{"summary":"Create a resource","tags":["Resources"],"description":"","produces":["application/json"],"parameters":[{"name":"resource","in":"body","description":"Resource","required":true,"schema":{"$ref":"#/definitions/ResourceRequest"}}],"responses":{"200":{"description":"Resource response","schema":{"type":"object","$ref":"#/definitions/ResourceResponse"}}}}},"/resources/{id}":{"put":{"summary":"Update a resource","tags":["Resources"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/id"},{"name":"resource","in":"body","description":"Resource","required":true,"schema":{"$ref":"#/definitions/ResourceRequest"}}],"responses":{"200":{"description":"Resource response","schema":{"type":"object","$ref":"#/definitions/ResourceResponse"}}}},"delete":{"summary":"Deletes a resource","tags":["Resources"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/id"}],"responses":{"200":{"description":"Resource response","schema":{"type":"object","$ref":"#/definitions/ResourceResponse"}}}},"get":{"summary":"Shows a resource","tags":["Resources"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/id"}],"responses":{"200":{}}}},"/class_categories":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Categories response","schema":{"type":"array","items":{"$ref":"#/definitions/CategoryResponse"}}}},"tags":["Class Categories"],"summary":"Returns all class categories","description":"","produces":["application/json"]},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Category response","schema":{"$ref":"#/definitions/CategoryResponse"}}},"tags":["Class Categories"],"summary":"Creates a Class category","description":"","produces":["application/json"],"parameters":[{"name":"name","in":"query","description":"name of the Class Category","required":true,"type":"string"}]}},"/class_categories/{id}":{"put":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Category response","schema":{"$ref":"#/definitions/CategoryResponse"}}},"tags":["Class Categories"],"summary":"Updates a Class Category","description":"","produces":["application/json"],"parameters":[{"name":"name","in":"query","description":"name of the Class Category","required":true,"type":"string"}]}},"/bundle_purchases":{"get":{"summary":"Returns all bundle purchases for a client","tags":["Bundle Purchases"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_id","in":"query","description":"Client ID","type":"integer","required":true},{"name":"bundle_all","in":"query","description":"Include all bundle related data","type":"boolean"},{"name":"bundle_purchase_item_groups","in":"query","description":"Include bundle purchase item groups","type":"boolean"},{"name":"bundle_purchase_events","in":"query","description":"Include bundle purchase events","type":"boolean"},{"name":"location","in":"query","description":"Include location data","type":"boolean"},{"name":"pos_ticket","in":"query","description":"Include POS ticket data","type":"boolean"}],"responses":{"200":{"description":"Bundle purchases response","schema":{"type":"object","properties":{"bundle_purchases":{"type":"array","items":{"$ref":"#/definitions/BundlePurchase"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"summary":"Creates a bundle purchase","tags":["Bundle Purchases"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_id","in":"query","description":"Client ID","type":"integer","required":true},{"name":"bundle_purchase","in":"body","description":"Bundle Purchase","required":true,"schema":{"$ref":"#/definitions/BundlePurchaseRequest"}}],"responses":{"200":{"description":"Bundle purchase response","schema":{"type":"object","properties":{"bundle_purchase":{"$ref":"#/definitions/BundlePurchase"}}}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/bundle_purchases/{id}":{"get":{"summary":"Get a bundle purchase","tags":["Bundle Purchases"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Bundle Purchase ID","type":"integer","required":true},{"name":"client_id","in":"query","description":"Client ID","type":"integer","required":true},{"name":"bundle_all","in":"query","description":"Include all bundle related data","type":"boolean"},{"name":"bundle_purchase_item_groups","in":"query","description":"Include bundle purchase item groups","type":"boolean"},{"name":"bundle_purchase_events","in":"query","description":"Include bundle purchase events","type":"boolean"},{"name":"location","in":"query","description":"Include location data","type":"boolean"},{"name":"pos_ticket","in":"query","description":"Include POS ticket data","type":"boolean"}],"responses":{"200":{"description":"Bundle purchase response","schema":{"type":"object","properties":{"bundle_purchase":{"$ref":"#/definitions/BundlePurchase"}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not found","schema":{"$ref":"#/definitions/ErrorModel"}}}},"put":{"summary":"Updates a bundle purchase","tags":["Bundle Purchases"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Bundle Purchase ID","type":"integer","required":true},{"name":"client_id","in":"query","description":"Client ID","type":"integer","required":true},{"name":"bundle_purchase","in":"body","description":"Bundle Purchase","required":true,"schema":{"$ref":"#/definitions/BundlePurchaseRequest"}}],"responses":{"200":{"description":"Bundle purchase response","schema":{"type":"object","properties":{"bundle_purchase":{"$ref":"#/definitions/BundlePurchase"}}}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}}}},"delete":{"summary":"Delete a bundle purchase","tags":["Bundle Purchases"],"description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Bundle Purchase ID","type":"integer","required":true},{"name":"client_id","in":"query","description":"Client ID","type":"integer","required":true}],"responses":{"200":{"description":"Success response"},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointment_groups":{"post":{"summary":"Creates an appointment group","tags":["Appointment Groups"],"description":"An appointment group links multiple appointments together so they are treated as a single booking (e.g. multi-pet visits or multi-service parties). Create a group, then attach appointments to it by sending the returned `id` as `appointment_group_id` on the appointment endpoints.","produces":["application/json"],"parameters":[{"$ref":"#/parameters/Subdomain"}],"responses":{"200":{"description":"Appointment group response","schema":{"type":"object","properties":{"appointment_group":{"$ref":"#/definitions/AppointmentGroup"}}}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/appointment_groups/{id}":{"get":{"summary":"Get an appointment group","tags":["Appointment Groups"],"description":"Returns an appointment group and, optionally, the join records identifying every appointment that belongs to it. Use this to retrieve the full set of appointments that share a single ticket / booking flow.","produces":["application/json"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Appointment Group ID","type":"integer","required":true},{"name":"appointment_group_items","in":"query","description":"When `true`, the response embeds the `appointment_group_items` array (one entry per appointment in the group, each carrying its `appointment_id`). Omit or set `false` to receive only the bare group.","type":"boolean"}],"responses":{"200":{"description":"Appointment group response","schema":{"type":"object","properties":{"appointment_group":{"$ref":"#/definitions/AppointmentGroup"}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not found","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/blockages":{"get":{"summary":"List blockages","description":"Returns blockages (time-off / unavailability windows) overlapping the requested date range. Filter by location and/or employee using either MyTime ids or partner/external ids. Recurring blockages are expanded to the individual occurrences that fall within the window.","produces":["application/json"],"tags":["Blockages"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"location_id","in":"query","description":"Filter by the location MyTime id. Provide this or `location_external_id`.","required":false,"type":"integer"},{"name":"location_external_id","in":"query","description":"Filter by the location partner/external id. A supplied value that does not resolve returns 404.","required":false,"type":"string"},{"name":"employee_id","in":"query","description":"Filter by the employee MyTime id. Provide this or `employee_external_id`.","required":false,"type":"integer"},{"name":"employee_external_id","in":"query","description":"Filter by the employee partner/external id. A supplied value that does not resolve returns 404.","required":false,"type":"string"},{"name":"start_date","in":"query","description":"ISO8601 start of the date range to list blockages for, e.g. 2026-07-01.","required":true,"type":"string","format":"date"},{"name":"end_date","in":"query","description":"ISO8601 end of the date range to list blockages for, e.g. 2026-07-31.","required":true,"type":"string","format":"date"}],"responses":{"200":{"description":"Blockages response","schema":{"type":"object","properties":{"blockages":{"type":"array","items":{"$ref":"#/definitions/BlockageResponse"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not found","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"summary":"Create a blockage","description":"Creates a one-off or recurring blockage. Reference the location and (optional) employee by MyTime id or partner/external id. Include a `schedule` to make the blockage recurring.","produces":["application/json"],"tags":["Blockages"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"blockage","in":"body","description":"Blockage attributes","required":true,"schema":{"$ref":"#/definitions/BlockageRequest"}}],"responses":{"201":{"description":"Created","schema":{"type":"object","properties":{"blockage":{"$ref":"#/definitions/BlockageResponse"}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not found","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/blockages/{id}":{"get":{"summary":"Get a blockage","description":"Returns a single blockage by its MyTime id.","produces":["application/json"],"tags":["Blockages"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Blockage MyTime id","required":true,"type":"integer"}],"responses":{"200":{"description":"Blockage response","schema":{"type":"object","properties":{"blockage":{"$ref":"#/definitions/BlockageResponse"}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not found","schema":{"$ref":"#/definitions/ErrorModel"}}}},"put":{"summary":"Update a blockage","description":"Updates a blockage. Only the fields you send are changed; omitted fields keep their current values. Omitting `schedule` preserves the existing recurrence; send `schedule: null` to turn a recurring blockage into a one-off.","produces":["application/json"],"tags":["Blockages"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Blockage MyTime id","required":true,"type":"integer"},{"name":"blockage","in":"body","description":"Blockage attributes to update","required":true,"schema":{"$ref":"#/definitions/BlockageRequest"}}],"responses":{"200":{"description":"Updated","schema":{"type":"object","properties":{"blockage":{"$ref":"#/definitions/BlockageResponse"}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not found","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}}}},"delete":{"summary":"Delete a blockage","description":"Soft-deletes a blockage by its MyTime id.","produces":["application/json"],"tags":["Blockages"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Blockage MyTime id","required":true,"type":"integer"}],"responses":{"200":{"description":"Deleted","schema":{"type":"object","properties":{"blockage":{"$ref":"#/definitions/BlockageResponse"}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not found","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/external_locations":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"External Location response","schema":{"type":"array","items":{"$ref":"#/definitions/ExternalLocationResponse"}}}},"summary":"Get all external locations","description":"Returns all external locations from a specific location","produces":["application/json"],"tags":["External Locations"],"parameters":[{"$ref":"#/parameters/Subdomain"}]},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"ExternalLocation response","schema":{"$ref":"#/definitions/ExternalLocationResponse"}}},"summary":"Create a external location","description":"Returns the newly created external locations","produces":["application/json"],"tags":["External Locations"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"company_id","type":"string","required":false,"in":"query"},{"name":"street_address","type":"string","required":true,"in":"query"},{"name":"street_address_2","type":"string","required":false,"in":"query"},{"name":"city","type":"string","required":true,"in":"query"},{"name":"state","type":"string","required":true,"in":"query"},{"name":"zip_code","type":"string","required":true,"in":"query"},{"name":"partner_id","type":"string","required":false,"in":"query"},{"name":"mytime_id","type":"string","required":false,"in":"query"},{"name":"country","type":"string","required":true,"in":"query"},{"name":"nickname","type":"string","required":false,"in":"query"}]}},"/external_locations/{id}":{"put":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"ExternalLocation response","schema":{"$ref":"#/definitions/ExternalLocationResponse"}}},"summary":"Update a external locations","description":"Returns the newly updated external locations","produces":["application/json"],"tags":["External Locations"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"},{"name":"id","in":"path","description":"The external location's id","required":true,"type":"string"},{"name":"company_id","type":"string","required":false,"in":"query"},{"name":"street_address","type":"string","required":true,"in":"query"},{"name":"street_address_2","type":"string","required":false,"in":"query"},{"name":"city","type":"string","required":true,"in":"query"},{"name":"state","type":"string","required":true,"in":"query"},{"name":"zip_code","type":"string","required":true,"in":"query"},{"name":"partner_id","type":"string","required":false,"in":"query"},{"name":"mytime_id","type":"string","required":false,"in":"query"},{"name":"country","type":"string","required":true,"in":"query"},{"name":"nickname","type":"string","required":false,"in":"query"}]},"delete":{"summary":"Delete external location","description":"Delete an external location","produces":["application/json"],"tags":["External Locations"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"The external location's id","required":true,"type":"string"},{"name":"id_is_partner","in":"query","description":"true - id is partner_id / false - id is mytime id","required":true,"type":"boolean"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/labels":{"get":{"summary":"Returns all labels for a given company","description":"\n        Labels are tags that can be attached to a particular client.","produces":["application/json"],"tags":["Labels"],"parameters":[{"$ref":"#/parameters/Subdomain"}],"responses":{"200":{"description":"Labels response","schema":{"type":"array","items":{"$ref":"#/definitions/Label"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/labels/{id}":{"delete":{"summary":"Delete label","description":"Delete an existing label","produces":["application/json"],"tags":["Labels"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"id","in":"path","description":"Id","required":true,"type":"string"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/custom_fields":{"get":{"summary":"Show all custom fields for a company","description":"Returns all custom fields for a given company","produces":["application/json"],"tags":["CustomField"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}],"responses":{"200":{"description":"Custom fields response","schema":{"type":"array","items":{"$ref":"#/definitions/CustomField"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/loyalty_program_points":{"get":{"summary":"Show Loyalty Program Points for a client","description":"returns loyalty program points for a client sent in the request","produces":["application/json"],"tags":["Loyalty Program Points"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_id","in":"query","description":"Client's mytime id","required":true,"type":"integer"}],"responses":{"200":{"description":"Shows loyalty points for a given client","schema":{"balance":"integer","client_id":"integer"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"summary":"Update Loyalty Program Points for a client","description":"returns loyalty program points for a client sent in the request","produces":["application/json"],"tags":["Loyalty Program Points"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"employee_id","in":"query","description":"Employee's mytime id","required":false,"type":"integer"},{"name":"client_id","in":"query","description":"Client's mytime id","required":true,"type":"integer"},{"name":"points","in":"query","description":"The number of points to add or take (+/-)","required":true,"type":"integer"}],"responses":{"200":{"description":"Updates the point balance for a given client with an amount of points +/-","schema":{"new_balance":"integer","client_id":"integer"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/staff_schedule":{"get":{"summary":"Get all staff schedule for a location ","description":"Returns all staff schedule for a date range, location and staff","produces":["application/json"],"tags":["StaffSchedule"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"employee_partner_id","in":"query","description":"The employee's id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"The employee's mytime id","required":false,"type":"integer"},{"name":"location_partner_id","in":"query","description":"The location's id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id. Either location_mytime_id or location_partner_id should be present","required":false,"type":"integer"},{"name":"start_date","in":"query","description":"The start date for the schedule e.g.: 2020-10-22","required":true,"type":"string"},{"name":"end_date","in":"query","description":"The end date for the schedule e.g.: 2020-11-22. Maximum date range between start and end date is 3 months","required":true,"type":"string"}],"responses":{"200":{"description":"Staff Schedule response","schema":{"type":"array","items":{"$ref":"#/definitions/StaffSchedule"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/staff_clocking":{"get":{"summary":"Returns all staff clocked date and time for a location","description":"\n        Returns all staff clocked hours and categories for a date range, location and staff\n      ","produces":["application/json"],"tags":["TimeTracking"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"employee_partner_id","in":"query","description":"The employee's id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"The employee's mytime id","required":false,"type":"integer"},{"name":"location_partner_id","in":"query","description":"The location's id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id. Either location_mytime_id or location_partner_id should be present","required":false,"type":"integer"},{"name":"start_date","in":"query","description":"The start date for the clocking e.g.: 2020-10-22","required":true,"type":"string"},{"name":"end_date","in":"query","description":"The end date for the clocking e.g.: 2020-11-22. Maximum date range between start and end date is 2 months","required":true,"type":"string"}],"responses":{"200":{"description":"Staff Clocking response","schema":{"type":"array","items":{"$ref":"#/definitions/StaffClocking"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/product_sales":{"get":{"summary":"Returns all Product Sales for a date range and location","description":"Returns all staff schedule for a date range, location and/or staff","produces":["application/json"],"tags":["ProductSales"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"employee_partner_id","in":"query","description":"The employee's id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"The employee's mytime id","required":false,"type":"integer"},{"name":"location_partner_id","in":"query","description":"The location's id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id. Either location_mytime_id or location_partner_id should be present","required":false,"type":"integer"},{"name":"start_date","in":"query","description":"The start date for the clocking e.g.: 2020-10-22","required":true,"type":"string"},{"name":"end_date","in":"query","description":"The end date for the clocking e.g.: 2020-11-22. Maximum date range between start and end date is 2 months","required":true,"type":"string"},{"name":"page","in":"query","description":"Pagination - results page number","required":false,"type":"string"},{"name":"per_page","in":"query","description":"Pagination - number of results per per_page. Default: 20. Maximum: 20","required":false,"type":"string"}],"responses":{"200":{"description":"Staff Clocking response","schema":{"type":"array","items":{"$ref":"#/definitions/ProductSales"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/service_sales":{"get":{"summary":"Returns Service sales for a location and date range","description":"\n        Returns all service sales for a date range, location and/or staff\n      ","produces":["application/json"],"tags":["ServiceSales"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"employee_partner_id","in":"query","description":"The employee's id","required":false,"type":"string"},{"name":"employee_mytime_id","in":"query","description":"The employee's mytime id","required":false,"type":"integer"},{"name":"location_partner_id","in":"query","description":"The location's id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id. Either location_mytime_id or location_partner_id should be present","required":false,"type":"integer"},{"name":"start_date","in":"query","description":"The start date for the clocking e.g.: 2020-10-22","required":true,"type":"string"},{"name":"end_date","in":"query","description":"The end date for the clocking e.g.: 2020-11-22. Maximum date range between start and end date is 2 months","required":true,"type":"string"}],"responses":{"200":{"description":"Staff Clocking response","schema":{"type":"array","items":{"$ref":"#/definitions/ServiceSales"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/forgot_password/token":{"post":{"summary":"Get a reset password token for the email","description":"Get a reset password token for the email","produces":["application/json"],"tags":["User"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"UserForgotPasswordTokenBody","in":"body","description":"UserForgotPasswordTokenBody","required":true,"schema":{"properties":{"email":{"type":"string","required":true,"description":"Email address"}}}}],"responses":{"200":{"description":"Forgot password response","schema":{"type":"object","properties":{"errors":{"$ref":"#/definitions/ErrorParameter"},"token":{"type":"string"}}}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/forgot_password/token_update":{"post":{"summary":"Update the users password using the reset pw token","description":"Update the users password using the reset pw token","produces":["application/json"],"tags":["User"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"UserForgotPasswordTokenUpdateBody","in":"body","description":"UserForgotPasswordTokenUpdateBody","required":true,"schema":{"properties":{"token":{"type":"string","description":"Forgot Password Token","required":true},"password":{"type":"string","description":"New Password","required":true}}}}],"responses":{"200":{"description":"Forgot password response","schema":{"type":"object","properties":{"errors":{"$ref":"#/definitions/ErrorParameter"},"success":{}}}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/companies":{"get":{"summary":"Get company","description":"Returns company","produces":["application/json"],"tags":["Company"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}],"responses":{"200":{"description":"Company response","schema":{"type":"array","items":{"$ref":"#/definitions/Company"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/employees":{"get":{"summary":"Returns all employees for a specific location.","description":"","produces":["application/json"],"tags":["Employees"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"location_partner_id","in":"query","description":"Filter employees by location using the partner (external) id","required":false,"type":"string"},{"name":"location_mytime_id","in":"query","description":"Filter employees by location using the MyTime id","required":false,"type":"string"},{"name":"with_deleted","in":"query","description":"Return deleted employees","required":false,"type":"boolean"},{"name":"sample_webhook","in":"query","description":"Whether or not to parse the employee in the same way the webhook parses it. Used for testing purposes. true/false","required":false,"type":"boolean"}],"responses":{"200":{"description":"employees response","schema":{"type":"array","items":{"$ref":"#/definitions/Employees"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/webhook_configurations":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"Webhook Configurations response","schema":{"type":"array","items":{"$ref":"#/definitions/WebhookConfigurationResponse"}}}},"tags":["WebhookConfigurations"],"summary":"Returns all webhook configurations","description":"","produces":["application/json"]},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"WebhookConfiguration response","schema":{"$ref":"#/definitions/WebhookConfigurationResponse"}}},"tags":["WebhookConfigurations"],"summary":"Creates an WebhookConfiguration","description":"","produces":["application/json"],"parameters":[{"name":"client_url","in":"query","description":"client_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"adjustment_event_url","in":"query","description":"adjustment_event_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"appointment_url","in":"query","description":"appointment_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"ticket_url","in":"query","description":"ticket_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"employee_url","in":"query","description":"employee_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"external_location_url","in":"query","description":"external_location_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"child_url","in":"query","description":"child_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"location_url","in":"query","description":"location_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"membership_template_url","in":"query","description":"membership_template_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"product_url","in":"query","description":"product_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"category_url","in":"query","description":"category_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"class_url","in":"query","description":"class_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"session_enrollment_url","in":"query","description":"session_enrollment_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"session_url","in":"query","description":"session_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"client_membership_url","in":"query","description":"client_membership_url of the WebhookConfiguration","required":false,"type":"string"},{"name":"bundle_purchase_url","in":"query","description":"bundle_purchase_url of the WebhookConfiguration","required":false,"type":"string"}]}},"/webhook_configurations/{id}":{"delete":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"WebhookConfiguration response","schema":{"$ref":"#/definitions/WebhookConfigurationResponse"}}},"tags":["WebhookConfigurations"],"summary":"Delete an webhook configuration","description":"","produces":["application/json"],"parameters":[{"$ref":"#/parameters/id"}]}},"/client_memberships":{"get":{"summary":"Client memberships of a client","description":"Return all client memberships of a client","produces":["application/json"],"tags":["Client Memberships"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"mytime_client_id","in":"query","require":true,"type":"integer"}],"responses":{"200":{"description":"client memberships response","schema":{"$ref":"#/definitions/ClientMembershipSimpleList"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not Found","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/client_memberships/{mytime_id}":{"put":{"summary":"Update a client membership","description":"Update a client membership","produces":["application/json"],"tags":["Client Memberships"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"mytime_id","in":"path","description":"Client membership ID","required":true,"type":"integer"},{"name":"upgrade_membership_template_mytime_id","in":"query","require":false,"type":"integer"},{"name":"custom_charge_date","in":"query","description":"Custom charge date e.g 2024-01-31","required":false,"type":"string","format":"Date"},{"name":"client_benefits","in":"body","description":"Client benefits to update values","required":false,"schema":{"$ref":"#/definitions/ClientBenefitSimpleRequestList"}}],"responses":{"200":{"description":"client memberships response","schema":{"$ref":"#/definitions/ClientMembershipSimpleList"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not Found","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/client_memberships/{mytime_id}/cancel":{"post":{"summary":"Cancel a client membership","description":"Cancel a client membership","produces":["application/json"],"tags":["Client Memberships"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"mytime_id","in":"path","description":"Client membership ID","required":true,"type":"integer"},{"name":"cancellation_date","in":"query","description":"Cancelation date e.g 2024-01-31","required":false,"type":"string","format":"Date"}],"responses":{"200":{"description":"client memberships response","schema":{"$ref":"#/definitions/ClientMembershipSimpleList"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not Found","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/client_memberships/{mytime_id}/retry_payment":{"post":{"summary":"Retry payment for a suspended client membership","description":"Retry payment for a suspended client membership to unsuspend it","produces":["application/json"],"tags":["Client Memberships"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"mytime_id","in":"path","description":"Client membership ID","required":true,"type":"integer"}],"responses":{"200":{"description":"client membership response","schema":{"$ref":"#/definitions/ClientMembershipSimple"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not Found","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Unprocessable Entity","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/client_memberships/webhook_samples":{"get":{"summary":"Webhook samples","description":"Retrieve webhook samples for client memberships","produces":["application/json"],"tags":["Client Memberships"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"limit","in":"query","description":"Max 20 samples","required":false,"type":"integer"}],"responses":{"200":{"description":"client memberships response","schema":{"$ref":"#/definitions/ClientMembershipWebhookSamplesList"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Not Found","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/categories":{"get":{"summary":"Lists Inventory Categories","description":"returns a list with all the Inventory Categories.","produces":["application/json"],"tags":["Inventory"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"page","in":"query","description":"Page requested","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"Number of records per page","required":false,"type":"integer"}],"responses":{"200":{"description":"lists categories available","schema":{"properties":{"inventory_categories":{"type":"array","items":{"$ref":"#/definitions/CategoryList"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/taxes":{"get":{"summary":"Lists Inventory taxes available for accounting","description":"returns a list with all the Taxes available for accounting system to use.","produces":["application/json"],"tags":["Inventory"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"$ref":"#/parameters/location_mytime_id"},{"name":"location_mytime_id","in":"query","description":"The location's mytime id","required":false,"type":"integer"},{"name":"page","in":"query","description":"Page requested","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"Number of records per page","required":false,"type":"integer"}],"responses":{"200":{"description":"lists taxes available","schema":{"properties":{"inventory_taxes":{"type":"array","items":{"$ref":"#/definitions/TaxResponse"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/withdrawal_types":{"get":{"summary":"Lists cash drawer withdrawal types available for accounting","description":"Returns the possible values of the withdrawal_type field on cash_drawers withdrawal entries.","produces":["application/json"],"tags":["PosAccountingRequests"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}],"responses":{"200":{"description":"lists withdrawal types available","schema":{"properties":{"withdrawal_types":{"type":"array","items":{"$ref":"#/definitions/WithdrawalTypeResponse"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"404":{"description":"Listing disabled","schema":{"properties":{"errors":{"type":"array","items":{"type":"string"}}}}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/skus":{"get":{"summary":"Returns all products available filtered according to parameters.","description":"Product list for a given company and location pair, optional category, paginated.","produces":["application/json"],"tags":["Inventory"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"inventory_category_mytime_id","in":"query","description":"Mytime's category id for the results","required":false,"type":"integer"},{"name":"page","in":"query","description":"Page number to return","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"row number to count as one page","required":false,"type":"integer"}],"responses":{"200":{"description":"Sku/Product list response","schema":{"properties":{"skus":{"type":"array","items":{"$ref":"#/definitions/SkuItem"}},"count":{"type":"integer"}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/purchase_orders":{"get":{"summary":"Returns purchase orders filtered by query parameters.","description":"Returns purchase orders for the company authenticated by X-Api-Key, paginated. Without location_mytime_id, the list may include purchase orders for all locations the user may access; pass location_mytime_id to restrict results to a single location. Pass updated_after to return only purchase orders updated after that timestamp. Results are ordered newest-first by id by default; pass sort and sort_order to override this.","produces":["application/json"],"tags":["Purchase Orders"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"$ref":"#/parameters/location_mytime_id"},{"name":"updated_after","in":"query","description":"Return only purchase orders with updated_at strictly after this value. ISO 8601 datetime (e.g. 2026-01-19 or 2026-01-19T00:00:00Z) is recommended.","required":false,"type":"string"},{"name":"page","in":"query","description":"Page number to return","required":false,"type":"integer"},{"name":"per_page","in":"query","description":"row number to count as one page","required":false,"type":"integer"},{"name":"sort","in":"query","description":"Field to sort by. Default is 'id'. Allowed values: id, updated_at.","required":false,"type":"string","enum":["id","updated_at"]},{"name":"sort_order","in":"query","description":"Sort direction. Default is 'desc' (newest first). Allowed values: asc, desc.","required":false,"type":"string","enum":["asc","desc"]},{"name":"vendor","in":"query","description":"Whether to include vendor information","required":false,"type":"boolean"},{"name":"purchase_order_items","in":"query","description":"Whether to include purchase order items","required":false,"type":"boolean"},{"name":"sku","in":"query","description":"Whether to include sku information","required":false,"type":"boolean"},{"name":"vendor_sku","in":"query","description":"Whether to include vendor sku information","required":false,"type":"boolean"},{"name":"shipment_items","in":"query","description":"Whether to include shipment items","required":false,"type":"boolean"},{"name":"shipments","in":"query","description":"Whether to include shipments","required":false,"type":"boolean"}],"responses":{"200":{"description":"Purchase order list response","schema":{"properties":{"purchase_orders":{"type":"array","items":{"$ref":"#/definitions/PurchaseOrder"}}}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/referral_program_information":{"get":{"summary":"Show referral program information for a client","description":"Returns referral program information for a client sent in the request","produces":["application/json"],"tags":["Referral Program Information"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_id","in":"query","description":"Client's mytime id","required":true,"type":"integer"}],"responses":{"200":{"description":"Shows referral program information for a given client","schema":{"$ref":"#/definitions/ReferralProgramInformation"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/pos_accounting_requests":{"get":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"PosAccountingRequests response","schema":{"properties":{"pos_accounting_requests":{"type":"array","items":{"$ref":"#/definitions/PosAccountingRequestObject"}}}}}},"summary":"List previous requests","description":"Returns a list of previous requests","produces":["application/json"],"tags":["PosAccountingRequests"],"parameters":[{"name":"location_mytime_id","in":"query","description":"Location MyTime ID","required":true,"type":"integer"},{"name":"date","in":"query","description":"Date of the requested export","required":true,"type":"date"},{"name":"show_events","in":"query","description":"Set to true to include events for each returned request","required":false,"type":"boolean"},{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}]},"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"PosAccountingRequests creation response","schema":{"properties":{"pos_accounting_request":{"$ref":"#/definitions/PosAccountingRequestObject"}}}}},"summary":"Create a new Pos Accounting Request","description":"Returns a pos accounting request that includes the event and the job id","produces":["application/json"],"tags":["PosAccountingRequests"],"parameters":[{"name":"location_mytime_id","in":"query","description":"Location MyTime ID","required":true,"type":"integer"},{"name":"date","in":"query","description":"Date for which we want the export","required":true,"type":"string"},{"name":"callback_url","in":"query","description":"URL on which MyTime will send back the response when it is ready","required":false,"type":"string"},{"name":"realtime","in":"query","description":"In case of realtime request - do not expect reponse on callback, set this to true","required":false,"type":"boolean"},{"name":"service_type","in":"query","description":"Type of the service request. Optional - If not sent is default to `tickets`. Options can be: `tickets`/`cash_drawers`/`expired_prepaids`/`reconciliation_items`/`vendor_returns`","required":false,"type":"string"},{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"}]}},"/pos_accounting_request_callbacks":{"post":{"responses":{"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}},"200":{"description":"PosAccountingRequestCallbacks creation response","schema":{"properties":{"pos_accounting_request_callback":{"$ref":"#/definitions/PosAccountingRequestCallbackObject"}}}}},"summary":"Create a new Pos Accounting Request Callback","description":"Returns a pos accounting request callback","produces":["application/json"],"tags":["PosAccountingRequestCallbacks"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"$ref":"#/parameters/Partner"},{"name":"body","in":"body","required":true,"description":"Callback payload","schema":{"type":"object","properties":{"request_params":{"type":"object","properties":{"location_id":{"type":"string"},"date":{"type":"string","format":"date"},"realtime":{"type":"string"}}},"mytime_response":{"type":"object","properties":{"http_status":{"type":"string"},"pos_accounting_request":{"type":"object","properties":{"id":{"type":"integer"},"errors":{"type":"string"}}},"started_at":{"type":"string","format":"date"}}},"accounting_response":{"type":"object","properties":{"http_status":{"type":"string"},"errors":{"type":"string"},"started_at":{"type":"string","format":"date"}}}}}}]}},"/clients/{client_id}/waitlist_items":{"get":{"summary":"Get all waitlist items for a client","description":"Returns all waitlist items for a particular client","produces":["application/json"],"tags":["Waitlist Items"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_id","in":"path","description":"The client's id","required":true,"type":"string"},{"name":"location_id","in":"query","description":"Filter by location","required":false,"type":"integer"},{"name":"employee_id","in":"query","description":"Filter by employee","required":false,"type":"integer"},{"name":"start_date","in":"query","description":"Filter by start date (ISO8601 format)","required":false,"type":"string","format":"date"},{"name":"end_date","in":"query","description":"Filter by end date (ISO8601 format)","required":false,"type":"string","format":"date"}],"responses":{"200":{"description":"Waitlist items response","schema":{"type":"array","items":{"$ref":"#/definitions/WaitlistItem"}}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}},"post":{"summary":"Create a waitlist item","description":"Create a new waitlist item for a client","produces":["application/json"],"consumes":["application/json"],"tags":["Waitlist Items"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_id","in":"path","description":"The client's id","required":true,"type":"string"},{"name":"body","in":"body","schema":{"type":"object","properties":{"location_id":{"type":"integer","description":"Location ID"},"employee_id":{"type":"integer","description":"Employee ID"},"variation_ids":{"type":"string","description":"Comma-separated variation IDs"},"begin_at":{"type":"string","format":"date-time","description":"Start time (ISO8601 format)"},"end_at":{"type":"string","format":"date-time","description":"End time (ISO8601 format)"},"kind":{"type":"string","enum":["appointment","session"],"description":"Type of waitlist item"},"session_id":{"type":"integer","description":"Session ID (required if kind is session)"},"attendee_ids":{"type":"array","items":{"type":"integer"},"description":"Attendee IDs (required if kind is session)"},"attendee_quantities":{"type":"array","items":{"type":"integer"},"description":"Attendee quantities (required if kind is session)"}}}}],"responses":{"201":{"description":"Waitlist item created","schema":{"$ref":"#/definitions/WaitlistItem"}},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}},"/clients/{client_id}/waitlist_items/{id}":{"delete":{"summary":"Delete a waitlist item","description":"Delete an existing waitlist item","produces":["application/json"],"tags":["Waitlist Items"],"parameters":[{"$ref":"#/parameters/Subdomain"},{"name":"client_id","in":"path","description":"The client's id","required":true,"type":"string"},{"name":"id","in":"path","description":"The waitlist item's id","required":true,"type":"string"}],"responses":{"204":{"description":"Deleted"},"401":{"description":"Unauthorized","schema":{"$ref":"#/definitions/ErrorModel"}},"422":{"description":"Invalid parameters","schema":{"$ref":"#/definitions/ErrorModel"}},"500":{"description":"Internal Server Error","schema":{"$ref":"#/definitions/ErrorModel"}},"504":{"description":"Gateway Timeout","schema":{"$ref":"#/definitions/ErrorModel"}}}}}},"definitions":{"SegmentResponse":{"allOf":[{"$ref":"#/definitions/Segment"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"Resource":{"properties":{"name":{"type":"string"},"location_id":{"type":"string"},"bookings_per_time_slot":{"type":"integer"},"available_for_clock_in":{"type":"boolean"}}},"ResourceRequest":{"allOf":[{"$ref":"#/definitions/Resource"},{"required":["name"]}]},"ResourceResponse":{"allOf":[{"properties":{"id":{"type":"integer"}},"$ref":"#/definitions/Resource"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"WebhookConfiguration":{"properties":{"client_url":{"type":"string"},"adjustment_event_url":{"type":"string"},"appointment_url":{"type":"string"},"ticket_url":{"type":"string"},"employee_url":{"type":"string"},"external_location_url":{"type":"string"},"child_url":{"type":"string"},"location_url":{"type":"string"},"membership_template_url":{"type":"string"},"product_url":{"type":"string"},"category_url":{"type":"string"},"class_url":{"type":"string"},"session_enrollment_url":{"type":"string"},"session_url":{"type":"string"},"client_membership_url":{"type":"string"},"bundle_purchase_url":{"type":"string"}}},"WebhookConfigurationRequest":{"allOf":[{"$ref":"#/definitions/WebhookConfiguration"}]},"WebhookConfigurationResponse":{"allOf":[{"properties":{"id":{"type":"integer"}},"$ref":"#/definitions/WebhookConfiguration"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"Segment":{"properties":{"slot_variation_id":{"type":"integer"},"position":{"type":"integer"},"kind":{"type":"string"},"duration":{"type":"integer"},"segment_template_id":{"type":"integer"},"my_class_session_id":{"type":"integer"},"segment_employees":{"type":"array","items":{"$ref":"#/definitions/SegmentEmployee"}},"segment_resources":{"type":"array","items":{"$ref":"#/definitions/SegmentResource"}}}},"SegmentVariationPostBody":{"description":"A time block within a service. Every service (variation) in MyTime is internally broken into one or more segments — a simple bath is one block; a full groom might be three: wash → process (dry/cool down) → finish. Each segment has a `kind`: `service` (staff is actively working), `processing` (gap where no staff is needed — drying, color processing, etc.), or `buffer` (turnover/cleanup time at the end). Every service has a default segment layout (its segment_templates) configured by the merchant; supplying a `segments` array in your POST instantiates those blocks for this one booking, optionally overriding default durations.","properties":{"position":{"type":"integer","description":"0-based order of this segment within the variation.","example":0},"kind":{"type":"string","enum":["service","processing","buffer"],"description":"\"service\" segments are attended in-chair time where staff is actively working; they contribute to the appointment duration. \"processing\" segments are unattended in-chair time between service segments where no staff is needed (e.g. drying, color processing) — they extend end_at (the client is still occupying the chair/room) but the employee is free to be booked on another appointment during them. \"buffer\" segments are turnover/cleanup time at the end and do not extend the appointment end_at.","example":"service"},"duration":{"type":"integer","description":"Segment length in minutes. Example: 120 for a 2-hour segment.","example":120},"segment_template_id":{"type":"integer","description":"ID of the segment template on the variation being booked. Obtain it from GET /variations/:id (segment_templates array).","example":7272},"segment_employees":{"type":"array","description":"Optional per-segment employee assignments. An appointment can span multiple segments either because a single service is composed of several segments (e.g. a couples service) or because the appointment mixes services owned by different employees (e.g. daycare + spa). Supply this to control which employee performs each segment. When provided for a segment, the named employee is assigned to that segment. When omitted, the segment falls back to the appointment-level employee.","items":{"properties":{"employee_mytime_id":{"type":"integer","description":"mytime ID of the employee assigned to this segment."}}}},"segment_resources":{"type":"array","description":"Optional resource assignments for this segment (e.g. room, equipment). Each entry pairs a resource with the requirement it fulfills on the segment template.","items":{"properties":{"resource_mytime_id":{"type":"integer","description":"mytime ID of the resource being assigned."},"requirement_id":{"type":"integer","description":"ID of the requirement on the segment template that this resource fulfills."}}}}}},"ClassSettingRequest":{"allOf":[{"$ref":"#/definitions/ClassSetting"},{"required":["company_id","class_id"],"properties":{"location_ids":{"type":"array","items":{"type":"integer"}}}}]},"ClassSetting":{"properties":{"name":{"type":"string"},"company_id":{"type":"integer"},"class_id":{"type":"integer"},"cancellation_policy":{"type":"integer"},"cancellation_interval":{"type":"integer"},"cancellation_value":{"type":"integer"}}},"ErrorItem":{"required":["type","message"],"properties":{"type":{"type":"string","enum":["invalid_type","required","blank","format","at_least","together_or_none","price_mismatch","negative","must_equal","be_within","less_or_equal","more_or_equal","min_length","max_length","already_exists","not_found","value_not_accepted","internal_error","other","read_timeout","bad_gateway","forbidden","is_invalid_option","unprocessable_entity","ACCESS_DENIED","API_CONFIGURATION_ERROR","AUTHORIZER_FAILURE","AUTHORIZER_CONFIGURATION_ERROR","BAD_REQUEST_PARAMETERS","BAD_REQUEST_BODY","DEFAULT_4XX","DEFAULT_5XX","EXPIRED_TOKEN","INVALID_SIGNATURE","INTEGRATION_FAILURE","INTEGRATION_TIMEOUT","INVALID_API_KEY","MISSING_AUTHENTICATION_TOKEN","QUOTA_EXCEEDED","REQUEST_TOO_LARGE","RESOURCE_NOT_FOUND","THROTTLED","UNAUTHORIZED","UNSUPPORTED_MEDIA_TYPES"]},"message":{"type":"string"}}},"Class":{"properties":{"name":{"type":"string"},"description":{"type":"string"},"what_to_bring":{"type":"string"},"category_id":{"type":"integer"},"company_id":{"type":"integer"}}},"SegmentEmployee":{"properties":{"id":{"type":"integer"},"employee_id":{"type":"integer"},"segment_id":{"type":"integer"}}},"SegmentResource":{"properties":{"id":{"type":"integer"},"resource_id":{"type":"integer"},"requirement_id":{"type":"integer"},"segment_id":{"type":"integer"}}},"SegmentTemplate":{"properties":{"id":{"type":"integer"},"kind":{"type":"string"},"position":{"type":"integer"},"duration":{"type":"integer"},"variation_id":{"type":"integer"},"durations":{"type":"array","items":{"$ref":"#/definitions/Duration"}}}},"Requirement":{"properties":{"id":{"type":"integer"},"segment_template_id":{"type":"integer"}}},"RequirementResponse":{"allOf":[{"$ref":"#/definitions/Requirement"},{"properties":{"requirement_resources":{"type":"array","description":"returned if requirement_resources param is set","items":{"$ref":"#/definitions/RequirementResourceResponse"}},"requirement_resource_ids":{"type":"array","description":"returned if requirement_resource_ids param is set","items":{"type":"integer"}},"requirement_employees":{"type":"array","description":"returned if requirement_employees param is set","items":{"$ref":"#/definitions/RequirementEmployeeResponse"}},"requirement_employee_ids":{"type":"array","description":"returned if requirement_employee_ids param is set","items":{"type":"integer"}},"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"SegmentTemplateResponse":{"allOf":[{"$ref":"#/definitions/SegmentTemplate"},{"properties":{"requirements":{"type":"array","description":"returned if requirements param is set","items":{"$ref":"#/definitions/RequirementResponse"}},"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"ClassSessionResponse":{"allOf":[{"properties":{"id":{"type":"integer","description":"id of class"}}},{"$ref":"#/definitions/ClassSession"},{"properties":{"segments":{"type":"array","description":"returned if segments param is set","items":{"$ref":"#/definitions/SegmentResponse"}}}}]},"SessionEnrollmentResponse":{"allOf":[{"properties":{"id":{"type":"integer","description":"id of class"}}},{"$ref":"#/definitions/SessionEnrollment"}]},"ClassResponse":{"allOf":[{"properties":{"id":{"type":"integer","description":"id of class"}}},{"$ref":"#/definitions/Class"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}},"category":{"type":"object","description":"returned if category param is set","$ref":"#/definitions/CategoryResponse"},"class_settings":{"type":"array","description":"returned if class_settings param is set","items":{"$ref":"#/definitions/ClassSettingResponse"}}}}]},"ClassSettingResponse":{"allOf":[{"properties":{"id":{"type":"integer","description":"id of class"}}},{"properties":{"segment_templates":{"type":"array","description":"returned if segment_templates param is set","items":{"$ref":"#/definitions/SegmentTemplateResponse"}}}}]},"RequirementResourceResponse":{"allOf":[{"$ref":"#/definitions/RequirementResource"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"RequirementEmployee":{"properties":{"id":{"type":"integer"},"requirement_id":{"type":"integer"},"employee_id":{"type":"integer"}}},"RequirementEmployeeResponse":{"allOf":[{"$ref":"#/definitions/RequirementEmployee"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"RequirementResource":{"properties":{"id":{"type":"integer"},"requirement_id":{"type":"integer"},"resource_id":{"type":"integer"}}},"CategoryRequest":{"allOf":[{"$ref":"#/definitions/Category"},{"required":["name"]}]},"CategoryResponse":{"allOf":[{"$ref":"#/definitions/Category"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"Category":{"properties":{"name":{"type":"string"}}},"TaxResponse":{"properties":{"mytime_id":{"type":"integer"},"name":{"type":"string"},"rate":{"type":"number"}}},"WithdrawalTypeResponse":{"properties":{"mytime_id":{"type":"string"},"name":{"type":"string"}}},"CategoryList":{"properties":{"mytime_id":{"type":"integer"},"name":{"type":"string"}}},"TicketItemTypeList":{"properties":{"mytime_id":{"type":"string"},"name":{"type":"string"}}},"TicketUpdateItem":{"type":"object","properties":{"type":{"type":"string","description":"Required for every item. The line item type: sku_item or misc_item."},"inventory_sku_id":{"type":"integer","description":"sku_item only. The inventory sku to add; the item is priced server-side (a caller-supplied amount is ignored)."},"quantity":{"type":"integer","description":"sku_item only. The quantity to add."},"note":{"type":"string","description":"misc_item only. The freeform line description."},"amount":{"type":"string","description":"misc_item only. The caller-set price for the line, e.g. \"15.00\"."}}},"TicketUpdateBody":{"type":"object","properties":{"items_attributes":{"type":"array","description":"Line items to append. Accepted fields depend on the item type: sku_item accepts [type, inventory_sku_id, quantity]; misc_item accepts [type, note, amount]. Any other field is ignored.","items":{"$ref":"#/definitions/TicketUpdateItem"}}}},"TicketObject":{"properties":{"mytime_id":{"type":"integer"},"uuid":{"type":"string"},"location_mytime_id":{"type":"integer"},"client":{"type":"string"},"created_at":{"type":"string"},"closed_at":{"type":"string"},"refund":{"type":"boolean","default":false},"items":{"type":"array","items":{"$ref":"#/definitions/TicketItemObject"}},"payment_items":{"type":"array","items":{"$ref":"#/definitions/TicketPaymentObject"}}}},"TicketItemObject":{"properties":{"item_type_mytime_id":{"type":"string"},"amount":{"type":"number"},"name":{"type":"string"},"deal_mytime_id":{"type":"integer","required":false},"variation_mytime_id":{"type":"integer","required":false},"sku_mytime_id":{"type":"integer","required":false},"inventory_category_mytime_id":{"type":"integer"},"taxes":{"required":false,"type":"array","items":{"$ref":"#/definitions/TicketTaxItem"}}}},"TicketPaymentObject":{"properties":{"payment_item_mytime_id":{"type":"string"},"amount":{"type":"number"},"name":{"type":"string","required":false}}},"TicketTaxItem":{"properties":{"tax_mytime_id":{"type":"integer"},"rate":{"type":"number"},"amount":{"type":"number"}}},"TicketItemDiscount":{"properties":{"name":{"type":"string"},"amount":{"type":"number"}}},"TicketPaymentTypeList":{"properties":{"payment_types":{"type":"array","items":{"properties":{"mytime_id":{"type":"string"},"name":{"type":"string"}}}}}},"SkuItem":{"properties":{"mytime_id":{"type":"integer"},"name":{"type":"string"},"inventory_category_mytime_id":{"type":"integer"}}},"ReconciliationList":{"properties":{"name":{"type":"string"},"amount":{"type":"number"},"created_at":{"type":"date"}}},"RoyaltyList":{"properties":{"uuid":{"type":"string"},"amount":{"type":"number"},"created_at":{"type":"date"}}},"SessionRequestSession":{"properties":{"company_id":{"type":"integer"},"location_id":{"type":"integer"},"class_id":{"type":"integer"},"begin_at":{"type":"string"},"end_at":{"type":"string"},"description":{"type":"string"},"class_setting_id":{"type":"integer"}}},"Session":{"properties":{"company_id":{"type":"integer"},"location_id":{"type":"integer"},"class_id":{"type":"integer"},"begin_at":{"type":"string"},"end_at":{"type":"string"},"status":{"type":"string"},"description":{"type":"string"},"capacity":{"type":"integer"},"price":{"type":"integer"},"orphan_at":{"type":"date"},"class_setting_id":{"type":"integer"}}},"AttendeeType":{"properties":{"id":{"type":"integer"},"name":{"type":"string"}}},"AttendeeRequest":{"allOf":[{"$ref":"#/definitions/AttendeeType"},{"required":["name"]}]},"AttendeeResponse":{"allOf":[{"$ref":"#/definitions/AttendeeType"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"SessionRequest":{"allOf":[{"properties":{"company_id":{"type":"integer"},"location_id":{"type":"integer"},"external_location_id":{"type":"integer"},"class_id":{"type":"integer"},"begin_at":{"type":"string"},"end_at":{"type":"string"},"description":{"type":"string"},"class_setting_id":{"type":"integer"}}},{"required":["name"]}]},"ClassRequest":{"allOf":[{"$ref":"#/definitions/Class"},{"required":["name","category_id"],"properties":{"class_settings":{"type":"array","items":{"$ref":"#/definitions/ClassSettingRequest"}}}}]},"ClientBenefit":{"allOf":[{"properties":{"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"}}}}]},"Benefit":{"allOf":[{"properties":{"type":{"type":"string"}}}]},"ClientMembership":{"allOf":[{"properties":{"mytime_id":{"type":"integer"},"partner_id":{"type":"integer"},"client_id":{"type":"integer"},"name":{"type":"string"},"membership_template_id":{"type":"integer"},"start_date":{"type":"string","format":"date-time"},"end_date":{"type":"string","format":"date-time"},"status":{"type":"string"},"membership_price":{"type":"number"},"registration_fee_amount":{"type":"number"},"cancellation_fee_amount":{"type":"number"},"pause_fee_amount":{"type":"number"},"my_client_child_id":{"type":"integer"},"payment_type":{"type":"integer"},"period_size":{"type":"integer"},"period_type":{"type":"boolean"},"billing_day":{"type":"integer"},"billing_retries_left":{"type":"integer"},"cancellation_date":{"type":"string","format":"date-time"},"pausing_start_date":{"type":"string","format":"date-time"},"pausing_end_date":{"type":"string","format":"date-time"},"rollover_unused_benefits_to_next_period":{"type":"boolean"},"past_pausing_duration_as_months":{"type":"integer"},"canceled_at":{"type":"stringtime","format":"date-time"},"custom_charge_date":{"type":"stringtime","format":"date-time"},"created_at":{"type":"stringtime","format":"date-time"},"source":{"type":"string"},"membership_purchase_id":{"type":"integer"},"date_of_last_charge":{"type":"string","format":"date-time"},"renewed_at":{"type":"stringtime","format":"date-time"},"maximum_pausing_duration_as_months":{"type":"integer"},"last_charged_amount":{"type":"number"},"next_charge_amount":{"type":"number"},"last_charged_date":{"type":"string","format":"date-time"},"next_charge_date":{"type":"string","format":"date-time"},"client_only":{"type":"boolean"},"next_eligible_pause_date":{"type":"string","format":"date-time"},"client_benefits":{"type":"array","items":{"$ref":"#/definitions/ClientBenefit"}}}}]},"ClientMembershipSimpleList":{"required":["client_memberships"],"properties":{"client_memberships":{"type":"array","items":{"$ref":"#/definitions/ClientMembershipSimple"}}}},"ClientBenefitSimpleRequest":{"properties":{"mytime_id":{"type":"integer"},"quantity":{"type":"number"},"type":{"type":"string","enum":["bundle_purchase","client_credit"]}}},"ClientBenefitSimpleRequestList":{"required":["client_benefits"],"properties":{"client_benefits":{"type":"array","items":{"$ref":"#/definitions/ClientBenefitSimpleRequest"}}}},"ClientBenefitClientCreditSimple":{"properties":{"mytime_id":{"type":"integer"},"current_amount":{"type":"integer"},"original_amount":{"type":"integer"},"type":{"type":"string","example":"client_credit"},"expires_at":{"type":"string","format":"date-time","nullable":true},"name":{"type":"string","nullable":true},"applies_to_all_skus":{"type":"string","nullable":true},"applies_to_all_variations":{"type":"string","nullable":true}}},"ClientBenefitBundlePurchaseSimple":{"properties":{"mytime_id":{"type":"integer"},"current_amount":{"type":"integer"},"original_amount":{"type":"integer"},"type":{"type":"string","example":"bundle_purchase"},"status":{"type":"string","nullable":true},"include_all_skus":{"type":"boolean"},"include_all_variations":{"type":"bollean"},"include_all_classes":{"type":"bollean"},"items":{"type":"array","nullable":true,"items":{"type":"string"}}}},"ClientMembershipSimple":{"properties":{"mytime_id":{"type":"integer"},"custom_charge_date":{"type":"string","format":"date-time"},"location":{"type":"object","properties":{"id":{"type":"integer"},"company_id":{"type":"integer"},"nickname":{"type":"string"}}},"name":{"type":"string"},"status":{"type":"string"},"client_benefits":{"type":"array","description":"Array of client benefits","items":{"anyOf":[{"$ref":"#/definitions/ClientBenefitBundlePurchaseSimple"},{"$ref":"#/definitions/ClientBenefitClientCreditSimple"}]}}}},"WebhookObject":{"properties":{"class":{"type":"string","description":"The class of the object"},"type":{"type":"string","description":"The type of the object"},"attrs":{"type":"object","description":"Attributes of the object","additionalProperties":true}}},"ClientMembershipWebhookSample":{"properties":{"mytime_id":{"type":"integer","nullable":true},"company_id":{"type":"integer"},"objects":{"type":"array","items":{"$ref":"#/definitions/WebhookObject"}},"action":{"type":"string","description":"The action performed on the client membership"},"class":{"type":"string","description":"The class name of the main object"},"user_id":{"type":"integer","nullable":true}}},"ClientMembershipWebhookSamplesList":{"required":["client_memberships"],"properties":{"client_memberships":{"type":"array","items":{"$ref":"#/definitions/ClientMembershipWebhookSample"}}}},"StaffSchedule":{"properties":{"schedule":{"type":"array","items":{"$ref":"#/definitions/StaffScheduleResponse"}}}},"StaffScheduleResponse":{"properties":{"employee_name":{"type":"string"},"employee_id":{"type":"integer"},"employee_mytime_id":{"type":"integer"},"avatar_url":{"type":"string"},"difference_question":{"type":"string"},"training_question":{"type":"string"},"worked_time":{"type":"integer"},"schedule_dates":{"type":"array","items":{"$ref":"#/definitions/ScheduleDates"}}}},"ScheduleDates":{"properties":{"date":{"type":"string"},"schedule_hours":{"type":"string"}}},"Employees":{"properties":{"id":{"type":"string"},"external_id":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"title":{"type":"string"},"user_id":{"type":"integer"}}},"ReferralProgramInformation":{"type":"object","description":"Statistics and details about the referral program","properties":{"statistics":{"type":"object","description":"Aggregated statistics for the referral program","properties":{"total_referrals":{"type":"integer","example":4},"total_referees":{"type":"integer","example":3},"total_activated_referrals":{"type":"integer","example":4},"total_earned_credit":{"type":"number","format":"float","example":35.0},"total_activated_credit":{"type":"number","format":"float","example":65.0}}},"referral_bonus":{"$ref":"#/definitions/ReferralBonus"},"referral_credit_balance":{"type":"number","format":"float"},"credit_used":{"type":"number","format":"float"},"credit_refunded":{"type":"number","format":"float"},"referrer":{"$ref":"#/definitions/ClientReferral"},"referral_link":{"type":"string"},"referees":{"type":"array","description":"List of referees and their referral details","items":{"$ref":"#/definitions/ClientReferral"}},"accepted_referees":{"type":"array","description":"List of accepted referees and their referral details","items":{"$ref":"#/definitions/ClientReferral"}},"pending_referees":{"type":"array","description":"List of pending referees and their referral details","items":{"$ref":"#/definitions/ClientReferral"}}}},"PosAccountingRequestObject":{"properties":{"id":{"type":"integer"},"started_at":{"type":"string"},"completed_at":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"failed_at":{"type":"string"},"status":{"type":"string"},"location_id":{"type":"integer"},"date":{"type":"string"},"callback_url":{"type":"string"},"service_type":{"type":"string"},"errors":{"type":"object"},"events":{"$ref":"#/definitions/PosAccountingRequestEventObject"}}},"PosAccountingRequestEventObject":{"properties":{"id":{"type":"integer"},"event":{"type":"string"},"job_id":{"type":"string"},"additional_data":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"}}},"ReferralBonus":{"properties":{"id":{"type":"integer"},"client_id":{"type":"integer"},"coupon_id":{"type":"integer"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"errors":{"type":"object"},"code":{"type":"string"},"value":{"type":"number","format":"float"},"balance":{"type":"number","format":"float"}}},"ClientReferral":{"description":"Referrer and their referral details","properties":{"id":{"type":"integer"},"activated_at":{"type":"string"},"data_type":{"type":"string"},"deleted_at":{"type":"string"},"earned_referee_credit":{"type":"number"},"earned_referrer_credit":{"type":"number"},"non_null_deleted":{"type":"integer"},"referee_credit":{"type":"number"},"referrer_credit":{"type":"number"},"ticket_amount":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"coupon_id":{"type":"integer"},"location_id":{"type":"integer"},"pos_ticket_id":{"type":"integer"},"referee_id":{"type":"integer"},"referrer_id":{"type":"integer"}}},"PosAccountingRequestCallbackObject":{"properties":{"id":{"type":"integer"},"location_id":{"type":"integer"},"date":{"type":"string"},"status":{"type":"string"},"pos_accounting_request_id":{"type":"integer"},"created_at":{"type":"string"},"updated_at":{"type":"string"}}},"PurchaseOrder":{"properties":{"id":{"type":"integer"},"deleted_at":{"type":"string"},"invoice_number":{"type":"string"},"last_exported_at":{"type":"string"},"non_null_deleted":{"type":"integer"},"ordered_at":{"type":"string"},"po_number":{"type":"string"},"shipping_cost":{"type":"number"},"status":{"type":"integer"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"external_id":{"type":"string"},"location_id":{"type":"integer"},"vendor_id":{"type":"integer"},"vendor_payment_method_id":{"type":"integer"}}},"WaitlistItem":{"properties":{"id":{"type":"integer"},"client_id":{"type":"integer"},"location_id":{"type":"integer"},"employee_id":{"type":"integer"},"child_id":{"type":"integer"},"kind":{"type":"string","enum":["appointment","session"]},"begin_at":{"type":"string","format":"date-time"},"end_at":{"type":"string","format":"date-time"},"session_id":{"type":"integer"},"variations":{"type":"array"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}},"ErrorModel":{"required":["errors"],"properties":{"errors":{"type":"object","$ref":"#/definitions/ErrorParameter"}}},"ErrorParameter":{"required":["parameter"],"type":"object","properties":{"parameter":{"type":"array","enum":["general","ANY_PARAMETER_SENT"],"items":{"$ref":"#/definitions/ErrorItem"}}}},"Company":{"required":[],"properties":{"id":{"type":"string"},"name":{"type":"string"},"child_company_name":{"type":"string"},"companies":{"type":"string"},"mytime_id":{"type":"integer"}}},"Client":{"required":["partner_id"],"properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"mobile_phone":{"type":"string"},"work_phone":{"type":"string"},"home_phone":{"type":"string"},"email":{"type":"string"},"contact_preference":{"type":"string"},"updated_at":{"type":"string"},"created_at":{"type":"string"},"appointment_count":{"type":"integer"},"can_book_online":{"type":"string"},"company_id":{"type":"string"},"source_quick_add":{"type":"string"},"has_missing_required_values":{"type":"string"},"can_receive_automated_emails":{"type":"boolean"},"can_receive_automated_sms":{"type":"boolean"},"can_receive_manual_emails":{"type":"boolean"},"can_receive_manual_sms":{"type":"boolean"},"can_receive_manual_sms_confirmed_at":{"type":"boolean"},"can_receive_automated_sms_confirmed_at":{"type":"boolean"},"has_card_on_file":{"type":"boolean"},"is_existing_customer":{"type":"boolean"},"associated_location_partner_ids":{"type":"array","items":{"type":"string"}},"associated_location_mytime_ids":{"type":"array","items":{"type":"string"}},"preferred_location_partner_id":{"type":"integer"},"preferred_location_mytime_id":{"type":"integer"},"children":{"items":{"$ref":"#/definitions/Child"}},"appointments":{"items":{"$ref":"#/definitions/Appointment"}},"addresses":{"items":{"$ref":"#/definitions/Address"}},"partner_id":{"type":"integer"}}},"Address":{"properties":{"id":{"type":"string"},"street_address":{"type":"string"},"street_address_2":{"type":"string"},"city":{"type":"string"},"zip":{"type":"string"},"state":{"type":"string"},"country":{"type":"string"}}},"CreateAddress":{"properties":{"street_address":{"type":"string"},"street_address_2":{"type":"string"},"city":{"type":"string"},"zip":{"type":"string"},"state":{"type":"string"},"country":{"type":"string"}}},"Child":{"required":["partner_id"],"properties":{"photo_url":{"type":"string"},"source_quick_add":{"type":"boolean"},"has_missing_required_values":{"type":"boolean"},"partner_id":{"type":"integer"}}},"OpenTime":{"required":[],"properties":{"min_price":{"type":"number"},"list_price":{"type":"number"},"begin_at":{"type":"string"},"end_at":{"type":"string"},"promoting":{"type":"string"},"employee_mytime_id":{"type":"string"},"location_mytime_id":{"type":"string"},"partner_id":{"type":"integer"}}},"Appointment":{"required":["begin_at","end_at","employee_mytime_id","location_mytime_id","client_mytime_id"],"properties":{"purchased_at_price":{"type":"number"},"begin_at":{"type":"string"},"end_at":{"type":"string"},"client_name":{"type":"string"},"client_email":{"type":"string"},"created_at":{"type":"string"},"status":{"type":"string"},"time_zone":{"type":"string"},"is_existing_customer":{"type":"string"},"client_phone":{"type":"string"},"variation_name":{"type":"string"},"full_address":{"type":"string"},"employee_partner_id":{"type":"integer"},"location_partner_id":{"type":"integer"},"client_partner_id":{"type":"integer"},"mytime_id":{"type":"string"},"client_mobile_phone":{"type":"string"},"client_home_phone":{"type":"string"},"client_work_phone":{"type":"string"},"checked_in_at":{"type":"string"},"checked_in":{"type":"string"},"checked_out_at":{"type":"string"},"pos_status":{"type":"string"},"address_id":{"type":"string"},"employee_requested":{"type":"string"},"child_partner_id":{"type":"integer"},"employee_mytime_id":{"type":"integer"},"location_mytime_id":{"type":"integer"},"client_mytime_id":{"type":"integer"},"child_mytime_id":{"type":"integer"},"variations":{"items":{"$ref":"#/definitions/Variation"}},"custom_field_values":{"items":{"$ref":"#/definitions/CustomFieldValue"}},"events":{"items":{"$ref":"#/definitions/Event"}},"partner_id":{"type":"integer"},"appointment_group_id":{"type":"integer","description":"ID of the appointment group this appointment belongs to, or null if it is not part of a group."}}},"VariationList":{"required":["variations"],"properties":{"variations":{"type":"array","items":{"$ref":"#/definitions/Variation"}}}},"Variation":{"required":["price","variation_partner_id","variation_mytime_id"],"description":"Variation booked on an appointment. To bill a variable-rate service (e.g. priced per minute or per attendee), send \"multiplier_base_price\" and \"price_multiplier\" together; omit both to use the variation's default pricing. When both are sent, \"price\" must equal multiplier_base_price * price_multiplier.","properties":{"price":{"type":"number","description":"Total charge for this variation. For multi-day stays (e.g. boarding), this is the total for the entire stay. When \"multiplier_base_price\" and \"price_multiplier\" are sent, this must equal their product.","example":120},"multiplier_base_price":{"type":"number","description":"Per-unit base price. Must be sent together with \"price_multiplier\" or omitted entirely.","example":40.0},"price_multiplier":{"type":"integer","description":"Number of units the base price is multiplied by (e.g. minutes, attendees). Must be sent together with \"multiplier_base_price\" or omitted entirely.","example":3},"variation_partner_id":{"type":"string","description":"Partner-side identifier of the service being booked."},"variation_mytime_id":{"type":"string","description":"MyTime identifier of the service being booked. Pull from GET /variations."},"parent_id":{"type":"string","description":"For add-on variations, references the parent variation in the same request. Match the parent’s variation_partner_id if provided, otherwise the parent’s variation_mytime_id (integer or string both accepted). The parent must appear earlier in the variations array than any add-on referencing it — an add-on cannot be the first entry, or the relationship is silently dropped. The add-on must also be configured as connectable to that parent service in the merchant catalog; otherwise the request fails with \"Add-on cannot be added-on for variation \u003cid\u003e\"."},"variation_employee_id":{"type":"string","description":"Staff assigned to this specific variation. Distinct from the appointment-level employee_mytime_id query param — lets different variations within one appointment be performed by different staff (e.g. a stylist for the cut and a colorist for the color)."},"variation_begin_at":{"type":"string","description":"Pins this variation to a specific start time within the appointment window. ISO 8601, e.g. 2026-05-15T10:00:00Z."},"variation_end_at":{"type":"string","description":"Pins this variation to a specific end time within the appointment window. See variation_begin_at. ISO 8601."}}},"DealVariation":{"required":["variation_partner_id","variation_mytime_id","name"],"properties":{"variation_partner_id":{"type":"string"},"variation_mytime_id":{"type":"string"},"name":{"type":"string"}}},"Variations":{"required":["variations"],"properties":{"variations":{"type":"array","items":{"$ref":"#/definitions/ServiceVariation"}}}},"ServiceVariation":{"properties":{"name":{"type":"string"},"service_name":{"type":"string"},"description":{"type":"string"},"external_id":{"type":"string"},"id":{"type":"integer"},"duration":{"type":"integer"},"add_on":{"type":"boolean"},"bookable":{"type":"boolean"},"pricings":{"type":"array","items":{"$ref":"#/definitions/VariationPricings"}},"segment_templates":{"type":"array","items":{"$ref":"#/definitions/SegmentTemplate"}}}},"VariationPricings":{},"VariationWithSegments":{"allOf":[{"$ref":"#/definitions/Variation"},{"properties":{"segments":{"type":"array","description":"Optional array of segment overrides for this variation. Each entry instantiates one of the variation’s segment_templates for this booking and lets you override per-segment `duration`. Omit the array to use the variation’s default segment durations. See SegmentVariationPostBody.","items":{"$ref":"#/definitions/SegmentVariationPostBody"}}}}]},"Duration":{"properties":{"id":{"type":"integer"},"employee_id":{"type":"integer","nullable":true},"location_id":{"type":"integer","nullable":true},"segment_template_id":{"type":"integer"},"time_span":{"type":"integer"}}},"Service":{"required":["service_id"],"properties":{"id":{"type":"integer"},"name":{"type":"string"},"status":{"type":"string"}}},"Deal":{"required":[],"properties":{"service_id":{"type":"string"},"location_partner_id":{"type":"integer"},"location_mytime_id":{"type":"integer"},"variations":{"$ref":"#/definitions/DealVariation"},"service":{"$ref":"#/definitions/Service"},"pricings":{"$ref":"#/definitions/Pricing"},"mytime_id":{"type":"integer"}}},"Location":{"required":["street_address","city","state","zip_code"],"properties":{"company_id":{"type":"string"},"street_address":{"type":"string"},"street_address_2":{"type":"string"},"city":{"type":"string"},"lat":{"type":"string"},"lng":{"type":"string"},"time_zone":{"type":"string"},"state":{"type":"string"},"zip_code":{"type":"string"},"phone_number":{"type":"string"},"mobile_number":{"type":"string"},"partner_id":{"type":"string"},"mytime_id":{"type":"integer"},"country":{"type":"string"},"nickname":{"type":"string"},"external_online_booking_url":{"type":"string"},"business_hours":{"type":"object","items":{"$ref":"#/definitions/BusinessHours"}}}},"BusinessHours":{"properties":{"Sunday":{"type":"object","items":{"$ref":"#/definitions/BusinessTimes"}},"Monday":{"type":"object","items":{"$ref":"#/definitions/BusinessTimes"}},"Tuesday":{"type":"object","items":{"$ref":"#/definitions/BusinessTimes"}},"Wednesday":{"type":"object","items":{"$ref":"#/definitions/BusinessTimes"}},"Thursday":{"type":"object","items":{"$ref":"#/definitions/BusinessTimes"}},"Friday":{"type":"object","items":{"$ref":"#/definitions/BusinessTimes"}},"Saturday":{"type":"object","items":{"$ref":"#/definitions/BusinessTimes"}}}},"BusinessTimes":{"properties":{"open_time":{"type":"string"},"close_time":{"type":"string"}}},"LocationResponse":{"required":["street_address","city","state","zip_code"],"properties":{"company_id":{"type":"string"},"street_address":{"type":"string"},"street_address_2":{"type":"string"},"city":{"type":"string"},"lat":{"type":"string"},"lng":{"type":"string"},"time_zone":{"type":"string"},"state":{"type":"string"},"zip_code":{"type":"string"},"phone_number":{"type":"string"},"mobile_number":{"type":"string"},"partner_id":{"type":"string"},"mytime_id":{"type":"integer"},"country":{"type":"string"},"nickname":{"type":"string"},"external_online_booking_url":{"type":"string"}}},"ExternalLocationResponse":{"required":["street_address","city","state","zip_code","country"],"properties":{"company_id":{"type":"string"},"street_address":{"type":"string"},"street_address_2":{"type":"string"},"city":{"type":"string"},"state":{"type":"string"},"zip_code":{"type":"string"},"partner_id":{"type":"string"},"mytime_id":{"type":"integer"},"country":{"type":"string"},"nickname":{"type":"string"}}},"Pricing":{"required":["new_min_price","new_list_price","existing_list_price","existing_min_price"],"properties":{"new_min_price":{"type":"number"},"new_list_price":{"type":"number"},"existing_list_price":{"type":"number"},"existing_min_price":{"type":"number"},"mytime_id":{"type":"integer"}}},"StaffClocking":{"type":"array","items":{"$ref":"#/definitions/StaffClockingResponse"}},"StaffClockingResponse":{"properties":{"date":{"type":"string"},"category_name":{"type":"string"},"employee_name":{"type":"string"},"location_name":{"type":"string"},"administrative_duration":{"type":"number"},"productive_duration":{"type":"number"},"clocking_duration":{"type":"number"},"employee_id":{"type":"integer"},"employee_mytime_id":{"type":"integer"},"start_time":{"type":"string","description":"DateTime in UTC"},"end_time":{"type":"string","description":"DateTime in UTC"}}},"ServiceSales":{"type":"array","items":{"$ref":"#/definitions/ServiceSale"}},"ServiceSale":{"properties":{"employee_name":{"type":"string"},"location_name":{"type":"string"},"client_name":{"type":"string"},"ticket_uuid":{"type":"string"},"total_services_revenue":{"type":"number"},"total_discounts":{"type":"number"},"total_refunds":{"type":"number"},"total_net_revenue_amount":{"type":"number"},"tax_amount":{"type":"number"},"tax_amount_refund":{"type":"number"},"ticket_id":{"type":"number"},"employee_id":{"type":"integer"},"employee_mytime_id":{"type":"integer"},"category":{"type":"string"},"service":{"type":"string"},"client_id":{"type":"integer"}}},"ProductSales":{"type":"array","items":{"$ref":"#/definitions/ProductSale"}},"ProductSale":{"properties":{"employee_name":{"type":"string"},"location_name":{"type":"string"},"client_name":{"type":"string"},"ticket_uuid":{"type":"string"},"amount":{"type":"number"},"total_discounts":{"type":"number"},"total_refunds":{"type":"number"},"total_net_revenue_amount":{"type":"number"},"tax_amount":{"type":"number"},"tax_amount_refund":{"type":"number"},"ticket_id":{"type":"number"},"employee_id":{"type":"integer"},"employee_mytime_id":{"type":"integer"},"category":{"type":"string"},"brand":{"type":"string"},"client_id":{"type":"integer"},"quantity":{"type":"integer"}}},"AppointmentPostBody":{"properties":{"booked_by":{"type":"string","description":"Booked by","required":false,"default":"merchant","options":["merchant","consumer"]},"partner_name":{"type":"string","description":"Partner Name to display in appointment notes","required":false,"default":"Partner API"},"variations":{"type":"array","description":"The variations objects","items":{"$ref":"#/definitions/VariationWithSegments"}},"notes":{"type":"array","description":"The notes objects","items":{"$ref":"#/definitions/Note"}},"custom_field_values":{"type":"array","description":"Per-appointment custom attribute values","items":{"$ref":"#/definitions/CustomFieldValue"}},"appointment_group_id":{"type":"integer","description":"Id of the appointment group this appointment belongs to. Two or more appointments sharing the same `appointment_group_id` are treated as a single booking (one ticket at checkout, one payment, grouped notifications). Obtain a group id by calling `POST /appointment_groups`."}},"example":{"booked_by":"merchant","partner_name":"Partner API","variations":[{"variation_mytime_id":309616,"price":100,"segments":[{"position":0,"kind":"service","duration":120,"segment_template_id":7272}]}]}},"Event":{"properties":{"action":{"type":"string"},"occurred_at":{"type":"string"},"appointment_previous_begin_at":{"type":"string"},"appointment_begin_at":{"type":"string"},"employee_partner_id":{"type":"integer"}}},"NoteList":{"required":["notes"],"properties":{"notes":{"type":"array","items":{"$ref":"#/definitions/Note"}}}},"Note":{"properties":{"content":{"type":"string"},"employee_partner_id":{"type":"string"},"id":{"type":"integer"},"employee_mytime_id":{"type":"integer"}}},"CustomFieldValueList":{"required":["custom_field_values"],"properties":{"custom_field_values":{"type":"array","items":{"$ref":"#/definitions/CustomFieldValue"}}}},"CustomFieldValue":{"properties":{"value":{"type":"string"},"custom_field_partner_id":{"type":"string"},"id":{"type":"integer"},"custom_field_mytime_id":{"type":"integer"}}},"CustomField":{"properties":{"partner_id":{"type":"string"},"uuid":{"type":"string"},"title":{"type":"string"},"resource_type":{"type":"string"},"mytime_id":{"type":"integer"},"hidden":{"type":"boolean"},"sort_order":{"type":"integer"}}},"ClassSessionEvent":{"properties":{"type":{"type":"string"},"created_at":{"type":"string"},"mytime_id":{"type":"string"},"employee_mytime_id":{"type":"integer"},"employee_partner_id":{"type":"integer"}}},"ClassSession":{"required":["begin_at","end_at","location_mytime_id","client_mytime_id","class_mytime_id","class_partner_id","status"],"properties":{"begin_at":{"type":"string"},"end_at":{"type":"string"},"created_at":{"type":"string"},"status":{"type":"string"},"mytime_id":{"type":"string"},"description":{"type":"string"},"what_to_bring":{"type":"string"},"employee_partner_id":{"type":"integer"},"location_partner_id":{"type":"integer"},"client_partner_id":{"type":"integer"},"child_partner_id":{"type":"integer"},"employee_mytime_id":{"type":"integer"},"location_mytime_id":{"type":"integer"},"client_mytime_id":{"type":"integer"},"child_mytime_id":{"type":"integer"},"class_mytime_id":{"type":"integer"},"class_partner_id":{"type":"integer"},"segments":{"type":"array","description":"returned if segments param is set","items":{"$ref":"#/definitions/SegmentResponse"}},"events":{"items":{"$ref":"#/definitions/ClassSessionEvent"}},"class":{"type":"object","$ref":"#/definitions/ClassResponse"},"partner_id":{"type":"integer"}}},"SessionEnrollment":{"required":["attendee_id","amount","client_mytime_id","client_partner_id","class_session_mytime_id","class_session_partner_id","status"],"properties":{"amount":{"type":"string"},"created_at":{"type":"string"},"status":{"type":"string"},"mytime_id":{"type":"string"},"attendee_id":{"type":"string"},"id":{"type":"integer"},"client_partner_id":{"type":"integer"},"child_partner_id":{"type":"integer"},"client_mytime_id":{"type":"integer"},"child_mytime_id":{"type":"integer"},"class_session_mytime_id":{"type":"integer"},"class_session_partner_id":{"type":"integer"},"partner_id":{"type":"integer"}}},"BundlePurchase":{"properties":{"id":{"type":"integer"},"bundle_id":{"type":"integer"},"my_client_client_id":{"type":"integer"},"location_id":{"type":"integer"},"company_id":{"type":"integer"},"bundle_company_id":{"type":"integer","description":"company_id of the bundle used when this purchase was purchased"},"name":{"type":"string"},"validity_start_time":{"type":"string","format":"date-time"},"validity_end_time":{"type":"string","format":"date-time"},"price":{"type":"number"},"amount":{"type":"number"},"amount_before_discount":{"type":"number"},"status":{"type":"string","enum":["active","inactive","refunded"]},"client_only":{"type":"boolean"},"my_client_child_id":{"type":"integer"},"commission_type":{"type":"integer","description":"0 - package price / 1 - retail price"},"commission_employee_id":{"type":"integer"},"for_child":{"type":"boolean"},"includes_used_usages":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"uuid":{"type":"string"},"external_id":{"type":"string"},"bundle_purchase_item_groups":{"type":"array","description":"Returned if bundle_purchase_item_groups or bundle_all param is set","items":{"$ref":"#/definitions/BundlePurchaseItemGroup"}},"bundle_purchase_events":{"type":"array","description":"Returned if bundle_purchase_events or bundle_all param is set","items":{"$ref":"#/definitions/BundlePurchaseEvent"}}}},"BundlePurchaseRequest":{"properties":{"bundle_id":{"type":"integer","description":"ID of the bundle to purchase"},"my_client_client_id":{"type":"integer","description":"Client ID"},"location_id":{"type":"integer","description":"Location ID"},"validity_start_time":{"type":"string","format":"date-time","description":"When the bundle purchase becomes valid"},"validity_end_time":{"type":"string","format":"date-time","description":"When the bundle purchase expires"},"price":{"type":"number","description":"Price of the bundle purchase"},"client_only":{"type":"boolean","description":"Whether the bundle is for the client only"},"my_client_child_id":{"type":"integer","description":"Child ID if the bundle is for a child"},"commission_type":{"type":"integer","description":"0 - package price / 1 - retail price"},"commission_employee_id":{"type":"integer","description":"Employee ID for commission"},"uuid":{"type":"string","description":"UUID for the bundle purchase"},"bundle_purchase_item_groups_attributes":{"type":"array","description":"Bundle purchase item groups","items":{"$ref":"#/definitions/BundlePurchaseItemGroupRequest"}}}},"BundlePurchaseItemGroup":{"properties":{"id":{"type":"integer"},"bundle_purchase_id":{"type":"integer"},"bundle_item_group_id":{"type":"integer"},"name":{"type":"string"},"default_quantity":{"type":"integer"},"remaining_quantity":{"type":"integer"},"include_all_skus":{"type":"boolean"},"include_all_variations":{"type":"boolean"},"include_all_classes":{"type":"boolean"}}},"BundlePurchaseItemGroupRequest":{"properties":{"bundle_item_group_id":{"type":"integer"},"quantity":{"type":"integer"}}},"BundlePurchaseEvent":{"properties":{"id":{"type":"integer"},"bundle_purchase_id":{"type":"integer"},"event_type":{"type":"string"},"created_at":{"type":"string","format":"date-time"}}},"AppointmentGroup":{"properties":{"id":{"type":"integer","description":"Group id. Pass this value as `appointment_group_id` on the appointment endpoints to attach an appointment to this group."},"company_id":{"type":"integer","description":"Id of the company that owns the group."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"appointment_group_items":{"type":"array","description":"Join records linking each member appointment to the group. Only returned when the `appointment_group_items` query param is set on `GET /appointment_groups/{id}`.","items":{"$ref":"#/definitions/AppointmentGroupItem"}}}},"AppointmentGroupItem":{"properties":{"id":{"type":"integer","description":"Id of the join record."},"appointment_group_id":{"type":"integer","description":"Id of the parent appointment group."},"appointment_id":{"type":"integer","description":"Id of the grouped appointment. Look up details via `GET /appointments/{id}`."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}},"AppointmentGroupRequest":{"type":"object","description":"Empty body — appointment groups have no public attributes","example":{}},"BlockageSchedule":{"type":"object","description":"Recurrence rule. Include to make the blockage recurring; omit (or send `null`) for a one-off window. On update, omitting this key preserves the existing recurrence.","properties":{"frequency_interval":{"type":"integer","description":"How often the blockage repeats, expressed in units of `interval_datatype` (e.g. `2` with `weeks` = every other week).","example":1},"interval_datatype":{"type":"string","enum":["days","weeks","months"],"description":"The unit the recurrence repeats on.","example":"weeks"},"end_date":{"type":"string","format":"date","description":"Optional ISO8601 date on which the recurrence stops. Omit for an open-ended series.","example":"2026-12-31"},"interval_extra":{"type":"object","description":"Optional fine-grained recurrence details. For `weeks`, supply `days_of_week` (a map of day index \"0\"=Sunday...\"6\"=Saturday to a boolean). For `months`, supply `month_option` (\"day_of_month\" or \"day_of_week\") plus the matching `month_day_of_month`, or `month_day_of_week` and `month_week`."}}},"Blockage":{"type":"object","properties":{"location_id":{"type":"integer","description":"MyTime id of the location the blockage applies to. Provide this or `location_external_id`."},"location_external_id":{"type":"string","description":"Partner/external id of the location. Resolved server-side to a MyTime location."},"employee_id":{"type":"integer","description":"MyTime id of the employee the blockage applies to. Omit (or send an id that does not resolve) for a location-wide blockage. Provide this or `employee_external_id`."},"employee_external_id":{"type":"string","description":"Partner/external id of the employee. Resolved server-side to a MyTime employee."},"begin_at":{"type":"string","format":"date-time","description":"ISO8601 start of the blocked-off window."},"end_at":{"type":"string","format":"date-time","description":"ISO8601 end of the blocked-off window."},"title":{"type":"string","description":"Free-form label shown on the calendar (e.g. \"Lunch\", \"Vacation\")."},"description":{"type":"string","description":"Optional longer note for the blockage."},"blockage_type":{"type":"string","description":"Free-form type. `day_off` marks the window as a day off; any other value is a generic block."},"resource_id":{"type":"integer","description":"Optional MyTime id of a resource (e.g. a room) the blockage reserves."},"schedule":{"$ref":"#/definitions/BlockageSchedule"}}},"BlockageRequest":{"allOf":[{"$ref":"#/definitions/Blockage"},{"required":["begin_at","end_at"]}],"example":{"location_id":0,"employee_id":0,"begin_at":"2026-07-10T12:09:28.048Z","end_at":"2026-07-10T12:09:28.048Z","title":"string","description":"string","blockage_type":"string","resource_id":0,"schedule":{"frequency_interval":1,"interval_datatype":"days","end_date":"2026-12-31","interval_extra":{}}}},"BlockageResponse":{"allOf":[{"properties":{"id":{"type":"integer"},"common_id":{"type":"string","description":"Stable per-occurrence identifier. For a recurring blockage this is \"{id}_r_{unix_begin_at}\"; otherwise the plain id."},"recurring":{"type":"boolean"},"is_original":{"type":"boolean"},"read_only":{"type":"boolean","description":"True for blockages synced in from an external calendar (not editable)."},"source":{"type":"string","description":"Origin of the blockage, e.g. `synced_calendar` or `import`; null for manually created."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"$ref":"#/definitions/Blockage"},{"properties":{"errors":{"type":"object","items":{"$ref":"#/definitions/ErrorItem"}}}}]},"Label":{"properties":{"name":{"type":"string"},"id":{"type":"integer"}}}}}