{"openapi":"3.0.3","info":{"title":"PerformYard API","description":"The PerformYard API allows customers to programmatically retrieve and manage data related to their performance management processes.","version":"0.1.0","contact":{"name":"PerformYard","url":"https://www.performyard.com/contact","email":"info@performyard.com"}},"components":{"securitySchemes":{"apiKey":{"type":"apiKey","name":"x-api-key","in":"header"},"apiId":{"type":"apiKey","name":"x-api-id","in":"header"}},"schemas":{}},"paths":{"/v1/auth/verify":{"get":{"summary":"Verify your API key and retrieve usage details","tags":["Auth"],"description":"Validates your API credentials and returns current usage metrics for your account, including rate limits and request counts.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"company_name":{"type":"string"},"last_used":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string","nullable":true,"enum":[null]}]},"is_enabled":{"type":"boolean"},"quota_limit":{"type":"number"},"requests_made":{"type":"number"},"refresh_period":{"anyOf":[{"type":"string","enum":["DAY"]},{"type":"string","enum":["WEEK"]},{"type":"string","enum":["MONTH"]},{"type":"string","enum":["NOT_FOUND"]}]}},"required":["company_name","last_used","is_enabled","quota_limit","requests_made","refresh_period"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/compensation-cycles":{"get":{"summary":"Retrieve a list of Compensation Cycles","tags":["Compensation"],"description":"Retrieves a list of all available compensation cycles created in your PerformYard instance. Please note, this endpoint requires the Compensation feature to be enabled for your company. Requests from a company without Compensation enabled are rejected with a 403.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"type":"string","enum":["active","completed","cancelled"]},"in":"query","name":"status","required":false,"description":"Filters the returned compensation cycles by a specific cycle status."},{"schema":{"type":"string"},"in":"query","name":"name","required":false,"description":"Filter the returned compensation cycles by a specific name. Accepts only a single string value. Case-insensitive."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"compensation_cycles":{"type":"array","items":{"type":"object","properties":{"id":{"anyOf":[{"type":"string"}]},"name":{"type":"string"},"status":{"type":"string","enum":["active","completed","cancelled"]},"display_status":{"type":"string","enum":["In Progress","Overdue","Scheduled","Completed","Cancelled"]},"start_date":{"type":"string","format":"date-time"},"due_date":{"type":"string","format":"date-time"},"completed_at":{"nullable":true,"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"},"employee_count":{"type":"number"},"created_by_name":{"type":"string"}},"required":["id","name","status","display_status","start_date","due_date","completed_at","created_at","employee_count","created_by_name"],"additionalProperties":false}}},"required":["compensation_cycles"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"422":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/compensation-cycles/{cycleId}":{"get":{"summary":"Retrieve a compensation cycle","tags":["Compensation"],"description":"Retrieves the details for a specific compensation cycle. Please note, this endpoint requires the Compensation feature to be enabled for your company. Requests from a company without Compensation enabled are rejected with a 403.","parameters":[{"schema":{"anyOf":[{"type":"string"}]},"in":"path","name":"cycleId","required":true,"description":"The id of the compensation cycle to retrieve."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"anyOf":[{"type":"string"}]},"name":{"type":"string"},"status":{"type":"string","enum":["active","completed","cancelled"]},"display_status":{"type":"string","enum":["In Progress","Overdue","Scheduled","Completed","Cancelled"]},"start_date":{"type":"string","format":"date-time"},"due_date":{"type":"string","format":"date-time"},"completed_at":{"nullable":true,"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"},"employee_count":{"type":"number"},"created_by_name":{"type":"string"}},"required":["id","name","status","display_status","start_date","due_date","completed_at","created_at","employee_count","created_by_name"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"422":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/compensation-cycles/{cycleId}/compensation-decisions":{"get":{"summary":"Retrieve a Compensation Cycle's decision information","tags":["Compensation"],"description":"Retrieves the decision information for a specific compensation cycle. Please note, this endpoint requires the Compensation feature to be enabled for your company. Requests from a company without Compensation enabled are rejected with a 403.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"anyOf":[{"type":"string"}]},"in":"path","name":"cycleId","required":true,"description":"The id of the compensation cycle whose decisions to retrieve."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"compensation_decisions":{"type":"array","items":{"type":"object","properties":{"employee_name":{"type":"string"},"employee_email":{"type":"string"},"job_title":{"type":"string"},"manager":{"type":"object","properties":{"name":{"nullable":true,"type":"string"},"email":{"nullable":true,"type":"string"}},"required":["name","email"],"additionalProperties":false},"acting_manager":{"type":"object","properties":{"name":{"nullable":true,"type":"string"},"email":{"nullable":true,"type":"string"}},"required":["name","email"],"additionalProperties":false},"current_salary":{"type":"number"},"currency":{"type":"string"},"increase_percent":{"nullable":true,"type":"number"},"increase_amount":{"nullable":true,"type":"number"},"new_salary":{"nullable":true,"type":"number"},"notes":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["Not Submitted","Submitted","Approved"]}},"required":["employee_name","employee_email","job_title","manager","acting_manager","current_salary","currency","increase_percent","increase_amount","new_salary","notes","status"],"additionalProperties":false}}},"required":["compensation_decisions"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"422":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/admin/data-fields/employee":{"get":{"summary":"Retrieve a list of employee data fields","tags":["Companies"],"description":"Retrieves all of the defined employee data fields configured in your PerformYard account, including field types, visibility, and editing permissions.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"anyOf":[{"type":"array","items":{"type":"string","enum":["department","phone","person","role","monetary","numeric","email","single-select","textbox","text","multi-select","people","date","salary","unknown"]}},{"type":"string","enum":["department","phone","person","role","monetary","numeric","email","single-select","textbox","text","multi-select","people","date","salary","unknown"]}]},"in":"query","name":"type","required":false,"description":"Filter the returned employee data fields by a specific data field type such as numeric, email, department, etc."},{"schema":{"anyOf":[{"type":"array","items":{"type":"string","enum":["admin","manager","self","all"]}},{"type":"string","enum":["admin","manager","self","all"]}]},"in":"query","name":"visible","required":false,"description":"Filter the returned employee data fields by which permission level can view the data field. Allowed Values: all, self, manager, admin"},{"schema":{"anyOf":[{"type":"array","items":{"type":"string","enum":["admin","manager","self","all"]}},{"type":"string","enum":["admin","manager","self","all"]}]},"in":"query","name":"editable","required":false,"description":"Filter the returned employee data fields by which permission level can edit the data field. Allowed Values: all, self, manager, admin"},{"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"in":"query","name":"tags","required":false,"description":"Filter the returned employee data fields by the tags that were added to the data fields. Case sensitive."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"employeeDataFields":{"type":"array","items":{"type":"object","properties":{"_id":{},"type":{"type":"string","enum":["department","phone","person","role","monetary","numeric","email","single-select","textbox","text","multi-select","people","date","salary","unknown"]},"name":{"type":"string"},"options":{"type":"array","items":{"type":"string"}},"tags":{"type":"array","items":{"type":"string"}},"created_at":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"}]},"is_required":{"type":"boolean"},"class":{"type":"string","enum":["standard","custom"]},"visible_by":{"type":"array","items":{"type":"string","enum":["admin","manager","self","all"]}},"editable_by":{"type":"array","items":{"type":"string","enum":["admin","manager","self","all"]}}},"required":["_id","type","name"],"additionalProperties":false}}},"required":["employeeDataFields"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/employees":{"get":{"summary":"Retrieve a list of employees","tags":["Employees"],"description":"Retrieves a list of all employees in your organization, with the option to return either basic profile data or complete employee records.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"type":"string","enum":["activated","deactivated"]},"in":"query","name":"employeeStatus","required":false,"description":"Filter the returned employees by a specific status."},{"schema":{"type":"string","enum":["billing admin","admin","basic admin","employee"]},"in":"query","name":"permissionLevel","required":false,"description":"Filter the returned employees by a specific PerformYard user role."},{"schema":{"type":"boolean"},"in":"query","name":"includeAllDataFields","required":false,"description":"Used to determine whether all data fields should be returned for each employee in the list."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"employees":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"type":"string","minLength":12,"maxLength":24}]},"name":{"nullable":true,"anyOf":[{"type":"string"}]},"email":{"nullable":true,"type":"string"},"phone":{"nullable":true,"anyOf":[{"type":"string"}]},"job_title":{"nullable":true,"anyOf":[{"type":"string"}]},"manager":{"nullable":true,"type":"object","properties":{"_id":{},"name":{"type":"string"},"email":{"type":"string"}},"required":["_id","name","email"],"additionalProperties":false},"contributors":{"nullable":true,"type":"array","items":{"type":"object","properties":{"_id":{},"name":{"type":"string"},"email":{"type":"string"}},"required":["_id","name","email"],"additionalProperties":false}},"group":{"nullable":true,"type":"object","properties":{"_id":{},"name":{"type":"string"}},"required":["_id","name"],"additionalProperties":false},"termination_date":{"nullable":true,"anyOf":[{"type":"string","format":"date-time"}]},"permission_level":{"type":"string","enum":["billing admin","admin","basic admin","employee"]},"employee_status":{"type":"string","enum":["activated","deactivated"]},"custom_fields":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"type":"string"}]},"field_name":{"nullable":true,"type":"string"},"field_value":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"},{"type":"number"},{"type":"string","nullable":true,"enum":[null]},{"type":"array","items":{"type":"string"}},{"type":"array","items":{}}]}},"required":["_id","field_value"],"additionalProperties":false}},"hire_date":{"nullable":true,"anyOf":[{"type":"string","format":"date-time"}]},"salary":{"type":"number","nullable":true}},"required":["_id"],"additionalProperties":false}}},"required":["employees"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}},"post":{"summary":"Create one or more employees","tags":["Employees"],"description":"Creates one or more new employees to your PerformYard account.","requestBody":{"content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"anyOf":[{"type":"string"}]},{"type":"string"}]},"first_name":{"description":"The employee's legal first name.","type":"string"},"last_name":{"description":"The employee's legal last name.","type":"string"},"nickname":{"description":"The employee's preferred or commonly used name. When an employee has nickname set, the name property on GET requests will follow the format \"nickname last_name\".","type":"string"},"email":{"description":"The employee's company or official email address. Must be a valid email format.","type":"string","minLength":1},"phone":{"description":"The employee's primary phone number. Dashes are optional.","type":"string"},"job_title":{"description":"The employee's official job title or role within the company.","type":"string"},"hire_date":{"description":"The date in which the employee was officially hired. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"termination_date":{"description":"The date in which the employee's employment ended. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"group":{"description":"The name of the group in which the employee belongs to. The group must exist in PerformYard.","type":"string"},"role":{"description":"The name or 24-character hex id of the role assigned to the employee. The role must exist in PerformYard; write-only for now, GET requests do not return this field.","type":"string"},"employee_status":{"description":"The current employment status of the employee.","type":"string","enum":["activated","deactivated"]},"manager":{"description":"The email address of the employee's direct manager.","type":"string"},"contributors":{"description":"The email address(es) of contributors to the employee.","type":"array","items":{"type":"string"}},"salary":{"anyOf":[{"type":"string"},{"type":"number"}]},"custom_fields":{"description":"Used to update the employee data fields created by the company. Accepts an array of objects where each object includes field_name and field_value, both of which accept a single string value.","type":"array","items":{"type":"object","properties":{"field_name":{"nullable":true,"type":"string"},"field_value":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"},{"type":"number"},{"type":"string","nullable":true,"enum":[null]},{"type":"array","items":{"type":"string"}},{"type":"array","items":{}}]}},"required":["field_value"]}}},"required":["email","employee_status"],"additionalProperties":false}}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}},"patch":{"summary":"Update multiple employees","tags":["Employees"],"description":"Performs bulk updates to multiple employee records in a single request.","requestBody":{"content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"_id":{"type":"string","minLength":1},"first_name":{"description":"The employee's legal first name.","type":"string"},"last_name":{"description":"The employee's legal last name.","type":"string"},"nickname":{"description":"The employee's preferred or commonly used name. When an employee has nickname set, the name property on GET requests will follow the format \"nickname last_name\".","type":"string"},"email":{"description":"The employee's company or official email address. Must be a valid email format.","type":"string"},"phone":{"description":"The employee's primary phone number. Dashes are optional.","type":"string"},"job_title":{"description":"The employee's official job title or role within the company.","type":"string"},"hire_date":{"description":"The date in which the employee was officially hired. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"termination_date":{"description":"The date in which the employee's employment ended. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"group":{"description":"The name of the group in which the employee belongs to. The group must exist in PerformYard.","type":"string"},"role":{"description":"The name or 24-character hex id of the role assigned to the employee. The role must exist in PerformYard; write-only for now, GET requests do not return this field.","type":"string"},"employee_status":{"description":"The current employment status of the employee.","type":"string","enum":["activated","deactivated"]},"manager":{"description":"The email address of the employee's direct manager.","type":"string"},"contributors":{"description":"The email address(es) of contributors to the employee.","type":"array","items":{"type":"string"}},"salary":{"anyOf":[{"type":"string"},{"type":"number"}]},"custom_fields":{"description":"Used to update the employee data fields created by the company. Accepts an array of objects where each object includes field_name and field_value, both of which accept a single string value.","type":"array","items":{"type":"object","properties":{"field_name":{"nullable":true,"type":"string"},"field_value":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"},{"type":"number"},{"type":"string","nullable":true,"enum":[null]},{"type":"array","items":{"type":"string"}},{"type":"array","items":{}}]}},"required":["field_value"]}}},"required":["_id"],"additionalProperties":false}}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/employees/{id}":{"get":{"summary":"Retrieve an employee","tags":["Employees"],"description":"Retrieves profile information for a specific employee, with the option to retrieve either basic details or the full employee record.","parameters":[{"schema":{"type":"boolean"},"in":"query","name":"includeAllDataFields","required":false,"description":"Used to determine whether all data fields should be returned for each employee in the list."},{"schema":{"anyOf":[{"type":"string"}]},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"employee":{"nullable":true,"type":"object","properties":{"_id":{"anyOf":[{"type":"string","minLength":12,"maxLength":24}]},"name":{"nullable":true,"anyOf":[{"type":"string"}]},"email":{"nullable":true,"type":"string"},"phone":{"nullable":true,"anyOf":[{"type":"string"}]},"job_title":{"nullable":true,"anyOf":[{"type":"string"}]},"manager":{"nullable":true,"type":"object","properties":{"_id":{},"name":{"type":"string"},"email":{"type":"string"}},"required":["_id","name","email"],"additionalProperties":false},"contributors":{"nullable":true,"type":"array","items":{"type":"object","properties":{"_id":{},"name":{"type":"string"},"email":{"type":"string"}},"required":["_id","name","email"],"additionalProperties":false}},"group":{"nullable":true,"type":"object","properties":{"_id":{},"name":{"type":"string"}},"required":["_id","name"],"additionalProperties":false},"termination_date":{"nullable":true,"anyOf":[{"type":"string","format":"date-time"}]},"permission_level":{"type":"string","enum":["billing admin","admin","basic admin","employee"]},"employee_status":{"type":"string","enum":["activated","deactivated"]},"custom_fields":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"type":"string"}]},"field_name":{"nullable":true,"type":"string"},"field_value":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"},{"type":"number"},{"type":"string","nullable":true,"enum":[null]},{"type":"array","items":{"type":"string"}},{"type":"array","items":{}}]}},"required":["_id","field_value"],"additionalProperties":false}},"hire_date":{"nullable":true,"anyOf":[{"type":"string","format":"date-time"}]},"salary":{"type":"number","nullable":true}},"required":["_id"],"additionalProperties":false}},"required":["employee"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}},"patch":{"summary":"Update an employee","tags":["Employees"],"description":"Modifies the profile information for a single employee.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"_id":{"anyOf":[{"anyOf":[{"type":"string"}]},{"type":"string"}]},"first_name":{"description":"The employee's legal first name.","type":"string"},"last_name":{"description":"The employee's legal last name.","type":"string"},"nickname":{"description":"The employee's preferred or commonly used name. When an employee has nickname set, the name property on GET requests will follow the format \"nickname last_name\".","type":"string"},"email":{"description":"The employee's company or official email address. Must be a valid email format.","type":"string"},"phone":{"description":"The employee's primary phone number. Dashes are optional.","type":"string"},"job_title":{"description":"The employee's official job title or role within the company.","type":"string"},"hire_date":{"description":"The date in which the employee was officially hired. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"termination_date":{"description":"The date in which the employee's employment ended. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"group":{"description":"The name of the group in which the employee belongs to. The group must exist in PerformYard.","type":"string"},"role":{"description":"The name or 24-character hex id of the role assigned to the employee. The role must exist in PerformYard; write-only for now, GET requests do not return this field.","type":"string"},"employee_status":{"description":"The current employment status of the employee.","type":"string","enum":["activated","deactivated"]},"manager":{"description":"The email address of the employee's direct manager.","type":"string"},"contributors":{"description":"The email address(es) of contributors to the employee.","type":"array","items":{"type":"string"}},"salary":{"anyOf":[{"type":"string"},{"type":"number"}]},"custom_fields":{"description":"Used to update the employee data fields created by the company. Accepts an array of objects where each object includes field_name and field_value, both of which accept a single string value.","type":"array","items":{"type":"object","properties":{"field_name":{"nullable":true,"type":"string"},"field_value":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"},{"type":"number"},{"type":"string","nullable":true,"enum":[null]},{"type":"array","items":{"type":"string"}},{"type":"array","items":{}}]}},"required":["field_value"]}}},"additionalProperties":false}}}},"parameters":[{"schema":{"anyOf":[{"type":"string"}]},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v2/employees":{"post":{"summary":"Create one or more employees","tags":["Employees"],"description":"Creates one or more new employees to your PerformYard account.","requestBody":{"content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"anyOf":[{"type":"string"}]},{"type":"string"}]},"first_name":{"description":"The employee's legal first name.","type":"string"},"last_name":{"description":"The employee's legal last name.","type":"string"},"nickname":{"description":"The employee's preferred or commonly used name. When an employee has nickname set, the name property on GET requests will follow the format \"nickname last_name\".","type":"string"},"email":{"description":"The employee's company or official email address. Must be a valid email format.","type":"string","minLength":1},"phone":{"description":"The employee's primary phone number. Dashes are optional.","type":"string"},"job_title":{"description":"The employee's official job title or role within the company.","type":"string"},"hire_date":{"description":"The date in which the employee was officially hired. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"termination_date":{"description":"The date in which the employee's employment ended. Allowed Formats: YYYY-MM-DD, MM-DD-YYYY.","anyOf":[{"type":"string"}]},"group":{"description":"The name of the group in which the employee belongs to. The group must exist in PerformYard.","type":"string"},"role":{"description":"The name or 24-character hex id of the role assigned to the employee. The role must exist in PerformYard; write-only for now, GET requests do not return this field.","type":"string"},"employee_status":{"description":"The current employment status of the employee.","type":"string","enum":["activated","deactivated"]},"manager":{"description":"The email address of the employee's direct manager.","type":"string"},"contributors":{"description":"The email address(es) of contributors to the employee.","type":"array","items":{"type":"string"}},"salary":{"anyOf":[{"type":"string"},{"type":"number"}]},"custom_fields":{"description":"Used to update the employee data fields created by the company. Accepts an array of objects where each object includes field_name and field_value, both of which accept a single string value.","type":"array","items":{"type":"object","properties":{"field_name":{"nullable":true,"type":"string"},"field_value":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"},{"type":"number"},{"type":"string","nullable":true,"enum":[null]},{"type":"array","items":{"type":"string"}},{"type":"array","items":{}}]}},"required":["field_value"]}}},"required":["email","employee_status"],"additionalProperties":false}}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"type":"string","minLength":12,"maxLength":24}]},"email":{"nullable":true,"type":"string"}},"required":["_id"],"additionalProperties":false}}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/goals":{"get":{"summary":"Retrieve a list of goals","tags":["Goals"],"description":"Retrieves all public and private goals across your organization with their current status and progress. Order first by status and then by name and due date. Please note, A goal's description will be delivered with escape characters for proper formatting in your database of choice.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"type":"string"},"in":"query","name":"name","required":false,"description":"Filter the returned goals by a specific name."},{"schema":{"type":"string","enum":["public","private"]},"in":"query","name":"transparency","required":false,"description":"Filters the returned goals by a specific transparency. Accepts public or private as options."},{"schema":{"anyOf":[{"type":"string"}]},"in":"query","name":"outlook","required":false,"description":"Filters the returned goals by a specific goal outlook. Accepts a single string value for name (case sensitive) or outlook ID."},{"schema":{"anyOf":[{"type":"string"}]},"in":"query","name":"category","required":false,"description":"Filters the returned goals by a specific goal category. Accepts a single string value for name (case sensitive) or category ID."},{"schema":{"type":"string","enum":["active","done","archived"]},"in":"query","name":"goalStatus","required":false,"description":"Filters the returned goals by a specific goal status."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"goals":{"type":"array","items":{"type":"object","properties":{"_id":{},"is_top":{"type":"boolean"},"start_date":{"type":"string","format":"date-time"},"categories":{"nullable":true,"type":"array","items":{"type":"object","properties":{"_id":{},"name":{"type":"string"}},"required":["_id","name"],"additionalProperties":false}},"initial_value":{"nullable":true,"type":"number"},"transparency":{"type":"string","enum":["private","public","super_public"]},"sharers":{"type":"array","items":{"type":"object","properties":{"_id":{},"email":{"type":"string"},"name":{"type":"string"}},"required":["_id","email","name"],"additionalProperties":false}},"target":{"type":"number"},"name":{"type":"string"},"description":{"type":"string"},"owner":{},"seen_by":{"type":"array","items":{"type":"string"}},"value":{"type":"number"},"assignee":{"type":"array","items":{"type":"object","properties":{"_id":{},"email":{"type":"string"},"name":{"type":"string"}},"required":["_id","email","name"],"additionalProperties":false}},"company":{},"last_update":{"type":"string","format":"date-time"},"units":{"type":"string"},"status":{"type":"string","enum":["active","archived","retired","deleted","done"]},"alignment":{"nullable":true},"deleted":{"type":"boolean"},"end_date":{"nullable":true,"type":"string","format":"date-time"},"outlook":{"nullable":true,"type":"object","properties":{"_id":{},"name":{"type":"string"},"color":{"type":"string"}},"required":["_id","name","color"],"additionalProperties":false},"goal_weight":{"nullable":true,"type":"number"},"checklist":{"nullable":true,"type":"array","items":{"type":"object","properties":{"_id":{},"text":{"type":"string"},"checked":{"type":"boolean"}},"required":["_id","text","checked"],"additionalProperties":false}},"checklist_updates_goal_progress":{"type":"boolean"}},"required":["_id","start_date","transparency","target","name","description","value","assignee","units","status"],"additionalProperties":false}}},"required":["goals"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}},"post":{"summary":"Create a goal","tags":["Goals"],"description":"Creates a new goal for the specified assignees. Please note, just like when creating a new goal in the PerformYard interface, adding multiple goal assignees will not assign multiple users to a single goal and will instead create one goal each for every assignee included.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"description":"Name of the goal being created.","type":"string","minLength":4,"maxLength":280},"assignment":{"description":"The user ID(s) of the employee(s) that will be assigned the goal being created.","minItems":1,"maxItems":50,"type":"array","items":{"type":"string"}},"transparency":{"description":"Defines who can see the goal being created.","type":"string"},"target":{"description":"The value you want to hit for the goal being created.","type":"number"},"units":{"description":"The type of units the goal being created will have for its target.","type":"string"},"start_date":{"description":"The start date of the goal. Accepted Format: YYYY-MM-DD.","type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"due_date":{"description":"Defines when the goal is due. Accepted Format: YYYY-MM-DD.","type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"is_top_level":{"description":"Defines whether the goal is a top level goal or not.","default":false,"type":"boolean"},"description":{"description":"The details of the goal being created.","type":"string"},"categories":{"description":"Defines the category or categories that the goal being created belongs to. Accepts an array of goal category IDs (strings). Goal categories can be retrieved using the GET /v1/goal-categories endpoint. If your organization has enabled the \"Require goal category when creating or editing goals\" setting, categories becomes a required field.","type":"array","items":{"type":"string"}},"goal_weight":{"description":"Defines the weight of the goal being created compared to other goals assigned to the same employee.","type":"number","minimum":0,"exclusiveMinimum":true},"alignment":{"description":"Defines the goal that the goal being created is aligned to. Must be a different goal's ID. Only a single goal ID is valid.","type":"string"},"checklist_updates_goal_progress":{"description":"Defines whether the goal's progress can be updated by its checklist.","default":false,"type":"boolean"}},"required":["name","assignment","transparency","target","start_date"],"additionalProperties":false}}},"required":true},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"ids":{"type":"array","items":{"type":"string"}}},"required":["message","ids"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"id":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"422":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errors":{"type":"array","items":{"type":"object","properties":{"index":{"type":"string"},"message":{"type":"string"},"path":{"type":"array","items":{"type":"string"}}},"required":["message","path"],"additionalProperties":false}},"id":{"type":"string"},"ids":{"type":"array","items":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/goals/{id}":{"get":{"summary":"Retrieve a goal","tags":["Goals"],"description":"Retrieves information for a specific goal. Please note, A goal's description will be delivered with escape characters for proper formatting in your database of choice.","parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"_id":{},"is_top":{"type":"boolean"},"start_date":{"type":"string","format":"date-time"},"categories":{"nullable":true,"type":"array","items":{"type":"object","properties":{"_id":{},"name":{"type":"string"}},"required":["_id","name"],"additionalProperties":false}},"initial_value":{"nullable":true,"type":"number"},"transparency":{"type":"string","enum":["private","public","super_public"]},"sharers":{"type":"array","items":{"type":"object","properties":{"_id":{},"email":{"type":"string"},"name":{"type":"string"}},"required":["_id","email","name"],"additionalProperties":false}},"target":{"type":"number"},"name":{"type":"string"},"description":{"type":"string"},"owner":{},"seen_by":{"type":"array","items":{"type":"string"}},"value":{"type":"number"},"assignee":{"type":"array","items":{"type":"object","properties":{"_id":{},"email":{"type":"string"},"name":{"type":"string"}},"required":["_id","email","name"],"additionalProperties":false}},"company":{},"last_update":{"type":"string","format":"date-time"},"units":{"type":"string"},"status":{"type":"string","enum":["active","archived","retired","deleted","done"]},"alignment":{"nullable":true},"deleted":{"type":"boolean"},"end_date":{"nullable":true,"type":"string","format":"date-time"},"outlook":{"nullable":true,"type":"object","properties":{"_id":{},"name":{"type":"string"},"color":{"type":"string"}},"required":["_id","name","color"],"additionalProperties":false},"goal_weight":{"nullable":true,"type":"number"},"checklist":{"nullable":true,"type":"array","items":{"type":"object","properties":{"_id":{},"text":{"type":"string"},"checked":{"type":"boolean"}},"required":["_id","text","checked"],"additionalProperties":false}},"checklist_updates_goal_progress":{"type":"boolean"}},"required":["_id","start_date","transparency","target","name","description","value","assignee","units","status"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"id":{"type":"string"}},"required":["message","id"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"id":{"type":"string"}},"required":["message","id"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}},"patch":{"summary":"Update a goal's details","tags":["Goals"],"description":"Modifies the properties of an existing goal, such as title, description, or due date. Does not update the goal's progress. That can be done using the endpoint entitled \"Update A Goal's Progress\". Please note, updates to a goal's attributes will also be recorded in the goal's activity history stream, where the label of the responsible API key will be displayed alongside the nature of the update.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"description":"Name of the goal being created.","type":"string","minLength":4,"maxLength":280},"target":{"description":"The value you want to hit for the goal being created.","type":"number","minimum":-1e+100,"maximum":1e+100},"units":{"description":"The type of units the goal being created will have for its target.","nullable":true,"type":"string"},"start_date":{"description":"The start date of the goal. Accepted Format: YYYY-MM-DD.","type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"due_date":{"description":"Defines when the goal is due. Accepted Format: YYYY-MM-DD.","nullable":true,"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"string","minLength":0,"maxLength":0}]},"description":{"description":"The details of the goal being created.","nullable":true,"type":"string"},"categories":{"description":"Defines the category or categories that the goal being created belongs to. Accepts an array of goal category IDs (strings). Goal categories can be retrieved using the GET /v1/goal-categories endpoint. If your organization has enabled the \"Require goal category when creating or editing goals\" setting, the behavior depends on whether the goal being updated already has categories: A) If the goal does not have categories, the category field becomes required and must be provided to update the goal. B) If the goal already has categories, the field remains optional and does not need to be included in the update.","type":"array","items":{"type":"string"}},"goal_weight":{"description":"Defines the weight of the goal being created compared to other goals assigned to the same employee.","nullable":true,"type":"number","minimum":0,"exclusiveMinimum":true},"transparency":{"description":"Defines who can see the goal being created.","type":"string"},"is_top_level":{"description":"Defines whether the goal is a top level goal or not.","type":"boolean"},"alignment":{"description":"Defines the goal that the goal being created is aligned to. Must be a different goal's ID. Only a single goal ID is valid.","nullable":true,"type":"string"},"checklist_updates_goal_progress":{"description":"Defines whether the goal's progress can be updated by its checklist.","default":false,"type":"boolean"}},"additionalProperties":false}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"id":{"type":"string"}},"required":["message","id"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"id":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"422":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errors":{"type":"array","items":{"type":"object","properties":{"index":{"type":"string"},"message":{"type":"string"},"path":{"type":"array","items":{"type":"string"}}},"required":["message","path"],"additionalProperties":false}},"id":{"type":"string"},"ids":{"type":"array","items":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/goals/{id}/update-progress":{"patch":{"summary":"Update a goal's progress","tags":["Goals"],"description":"Updates the value of a goal's progress. Please note, updates to a goal's attributes will also be recorded in the goal's activity history stream, where the label of the responsible API key will be displayed alongside the nature of the update. Archived & completed goals cannot have their progress updated. Users attempting to update these goals will receive an error message indicating their status as an archived or completed goal.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"update_type":{"description":"Set how to alter the current goal progress value. Possible Values: absolute, incremental. absolute - Overwrites the current goal progress value with the value passed in for value. incremental - Adds the passed in value to the current goal progress value.","type":"string"},"value":{"description":"The value of this goal's progress.","type":"number","minimum":-1e+100,"maximum":1e+100},"as_of_date":{"description":"The progress of this goal as of a certain date. Accepted Format: YYYY-MM-DD.","type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"message":{"description":"Text to be added to the goal being updated activity stream on update.","type":"string"},"outlook":{"description":"The ID that uniquely identifies the current outlook of the goal being updated. Accepts a single string value. Goal outlooks can be retrieved using the GET /v1/goal-outlooks endpoint.","type":"string"}},"required":["update_type","value","as_of_date"],"additionalProperties":false}}},"required":true},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"id":{"type":"string"}},"required":["message","id"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"id":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"422":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errors":{"type":"array","items":{"type":"object","properties":{"index":{"type":"string"},"message":{"type":"string"},"path":{"type":"array","items":{"type":"string"}}},"required":["message","path"],"additionalProperties":false}},"id":{"type":"string"},"ids":{"type":"array","items":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/goal-categories":{"get":{"summary":"Retrieve a list of goal categories","tags":["Goals"],"description":"Retrieves the list of goal categories configured in your organization.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"_id":{},"company":{},"name":{"type":"string"},"deleted":{"type":"boolean"},"deleter":{},"deletion_date":{"type":"string","format":"date-time"}},"required":["_id","name"],"additionalProperties":false}}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/goal-outlooks":{"get":{"summary":"Retrieve a list of goal outlooks","tags":["Goals"],"description":"Retrieves the list of goal outlooks configured in your organization.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"_id":{},"color":{"type":"string"},"company":{},"name":{"type":"string"},"order":{"type":"number"},"deleted":{"type":"boolean"},"deleter":{},"deletion_date":{"type":"string","format":"date-time"}},"required":["_id","color","name"],"additionalProperties":false}}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}}},"/health":{"get":{"summary":"Check API status","tags":["Health"],"description":"Checks the operational status of the PerformYard API and returns system availability information.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"healthy":{"type":"boolean"},"gitHash":{"type":"string"},"gitHashShort":{"type":"string"},"gitBranch":{"type":"string"},"environment":{"type":"string"}},"required":["healthy","gitHash","gitHashShort","gitBranch","environment"],"additionalProperties":false}}}}}}},"/v1/reports":{"get":{"summary":"Retrieve a list of reports","tags":["Reporting"],"description":"Retrieves a list of all available reports created in your PerformYard instance.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}]},"in":"query","name":"tags","required":false,"description":"Filter the returned reports by a specific tag. Accepts only a single string value. Case sensitive."},{"schema":{"type":"string"},"in":"query","name":"name","required":false,"description":"Filter the returned reports by a specific name. Accepts only a single string value. Case sensitive."},{"schema":{},"in":"query","name":"companyId","required":false},{"schema":{"type":"string","enum":["employeeReport","reviewReport","goalReport","surveyReport"]},"in":"query","name":"type","required":false,"description":"The type of report to return."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"reports":{"type":"array","items":{"type":"object","properties":{"_id":{},"name":{"type":"string"},"type":{"type":"string","enum":["employeeReport","reviewReport","employee","goalReport","surveyReport"]},"description":{"type":"string"},"created_at":{"anyOf":[{"type":"string"},{"type":"string","format":"date-time"}]},"created_by":{"nullable":true,"anyOf":[{"type":"string"}]},"last_updated":{"default":"","anyOf":[{"type":"string"},{"type":"string","format":"date-time"}]},"tags":{"default":[],"type":"array","items":{"type":"string"}}},"required":["_id","name","type","created_at","last_updated","tags"],"additionalProperties":false}}},"required":["reports"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/reports/{id}":{"get":{"summary":"Retrieve a report's data","tags":["Reporting"],"description":"Retrieves the data and results for a specific report, including all rows and calculated values. This endpoint returns a maximum of 200 data rows per request. For reports exceeding this limit, use the offset query parameter to retrieve all data through multiple requests. The offset value represents which page of results to return, starting at 0 for the first page. For example, a report with 450 rows requires three API calls: the first with offset=0 returns rows 1-200, the second with offset=1 returns rows 201-400, and the third with offset=2 returns the remaining rows 401-450. Continue incrementing the offset until you receive fewer than 200 rows, indicating you've reached the end of the dataset.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"anyOf":[{"type":"string"}]},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"review_report":{"type":"array","items":{}},"employee_report":{"type":"array","items":{}},"goal_report":{"type":"array","items":{}},"survey_report":{"type":"array","items":{}}},"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/reviews":{"post":{"summary":"Create a review for an employee","tags":["Reviews"],"description":"Creates a new performance review for a specific employee using the specified template.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"subjectId":{"description":"The employee the review is being created for.","anyOf":[{"type":"string"}]},"templateId":{"description":"The template to use when creating the review.","anyOf":[{"type":"string"}]},"startDate":{"description":"The date of when the review should start. Accepted Format: YYYY-MM-DD.","type":"string"},"startTime":{"description":"The time when the review should start. Default value is based on company default review time. Timezone is based on company timezone.","type":"string","enum":["midnight","9am","noon","5pm"]}},"required":["subjectId","templateId","startDate"]}}},"required":true},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/review-templates":{"get":{"summary":"Retrieve a list of review templates","tags":["Review Templates"],"description":"Retrieves all available review templates, including their name and the number of forms it contains.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"type":"string"},"in":"query","name":"name","required":false,"description":"Filter the returned review templates by a specific name."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"reviewTemplates":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"type":"string"}]},"name":{"type":"string"},"last_updated":{"type":"string","format":"date-time"},"number_of_forms":{"type":"number"}},"required":["_id","name","number_of_forms"],"additionalProperties":false}}},"required":["reviewTemplates"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/review-cycles":{"get":{"summary":"Retrieve a list of review cycles","tags":["Reviews","Review Cycles"],"description":"Retrieves all performance review cycles, including their status, start dates, and types.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"Used to paginate through a list of records. Can be combined with limit. Increment the value by one to fetch subsequent pages (1 for the second page, 2 for the third, etc.)."},{"schema":{"type":"string"},"in":"query","name":"sort","required":false,"description":"Order in which to return the records. Allowed Values: asc(FIELD_NAME), desc(FIELD_NAME)."},{"schema":{"type":"string"},"in":"query","name":"name","required":false,"description":"Filter the returned review cycles by a specific name. Case sensitive."},{"schema":{"type":"string","enum":["Completed","Scheduled","Active","N/A"]},"in":"query","name":"status","required":false,"description":"Filter the returned review cycles by a specific status."},{"schema":{"type":"string","enum":["manual","automated","group"]},"in":"query","name":"type","required":false,"description":"The type of review cycle to return."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"review_cycles":{"type":"array","items":{"type":"object","properties":{"id":{"anyOf":[{"type":"string"}]},"name":{"type":"string"},"start_date":{"type":"string","format":"date-time"},"completed":{"type":"boolean"},"status":{"type":"string","enum":["Completed","Scheduled","Active","N/A"]},"type":{"type":"string","enum":["manual","automated","group"]}},"required":["id","name","start_date","completed","status","type"],"additionalProperties":false}}},"required":["review_cycles"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/review-cycles/{reviewCycleId}/subjects":{"post":{"summary":"Add an employee to a review cycle","tags":["Reviews","Review Cycles"],"description":"Adds a specific employee as a review subject using the specified review cycle.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"subjectId":{"description":"The employee being added to the review cycle.","anyOf":[{"type":"string"}]},"startDate":{"description":"The date of when the review should start. Accepted Format: YYYY-MM-DD.","type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"startTime":{"description":"The time when the review should start. Default value is based on company default review time. Timezone is based on company timezone.","type":"string","enum":["midnight","9am","noon","5pm"]},"adminEdit":{"description":"Restricts editing permissions to just admins for this created review within the specified review cycle (update author/signers, add/remove forms). Management of created review can be done within PerformYard.","type":"boolean"}},"required":["subjectId","startDate"]}}},"required":true},"parameters":[{"schema":{"anyOf":[{"type":"string"}]},"in":"path","name":"reviewCycleId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","enum":["Employee added to review cycle."]}},"required":["message"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/v1/roles":{"get":{"summary":"Retrieve a list of roles","tags":["Roles"],"description":"Retrieves the company's active roles, for use as valid values on the employee Role field.","parameters":[{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"limit","required":false,"description":"The number of records to be returned in a single API Request."},{"schema":{"type":"string","pattern":"^[0-9]+$"},"in":"query","name":"offset","required":false,"description":"The number of documents to skip before returning results. For the next page, increase this value by the limit used in the request (e.g. offset=5 with limit=5 returns the next 5 roles)."}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"roles":{"type":"array","items":{"type":"object","properties":{"_id":{"anyOf":[{"type":"string","minLength":12,"maxLength":24}]},"name":{"type":"string"}},"required":["_id","name"],"additionalProperties":false}}},"required":["roles"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"details":{"type":"array","items":{"type":"string"}},"meta":{"type":"object","additionalProperties":{"type":"string"}}},"required":["message"],"additionalProperties":false}}}}}}},"/swagger.json":{"get":{"summary":"Retrieve our Swagger JSON definition","tags":["Swagger"],"description":"Swagger JSON","responses":{"200":{"description":"Default Response"}}}}},"servers":[{"url":"https://api.talent.performyard.com/"}],"externalDocs":{"url":"https://support.performyard.com/article/183-api-reference","description":"PerformYard API Reference"}}