basePath: /v1 definitions: gapi.ExportFileType: enum: - 0 - 1 type: integer x-enum-varnames: - ExportFilterTypeCSV - ExportFilterTypeXLSX model.CreateCustomerParams: properties: managers: description: The list of managers associated to the customer items: format: uuid type: string type: array name: description: The customer's name type: string required: - name type: object model.CreateDeclarationParams: properties: date: description: The declaration date format: date type: string description: description: The description of the declaration maxLength: 256 type: string x-nullable: true duration: description: The duration of the declaration in seconds type: integer task_id: description: The task's identifier associated to the declaration format: uuid type: string user_id: description: The user's identifier associated to the declaration format: uuid type: string required: - date - duration - task_id - user_id type: object model.CreateDiscountParams: properties: amount: description: The discount's amount type: number name: description: The discount's name type: string project_id: description: The project's identifier associated to the discount (required if task_id is empty) format: uuid type: string x-nullable: true task_id: description: The task's identifier associated to the discount (required if project_id is empty) format: uuid type: string x-nullable: true required: - name type: object model.CreateLeavePeriodParams: properties: delete_declaration: description: A param to delete declarations if they exist type: boolean x-nullable: true description: description: The description of the leave period maxLength: 128 type: string end_at: description: The end at date format: date type: string end_type: description: The end type enum: - full - am - pm type: string start_at: description: The start at date format: date type: string start_type: description: The start type enum: - full - am - pm type: string user_id: description: The user's identifier associated to the leave period format: uuid type: string type: object model.CreateProjectParams: properties: code: description: The project's code maxLength: 36 type: string x-nullable: true contributors: description: The list of contributors (must be empty when visibility="public") items: format: uuid type: string type: array customer_id: description: The customer's identifier associated to the project format: uuid type: string x-nullable: true end_at: description: An UTC time indicating when the project is supposed to end format: date type: string groups: description: User group assignments items: format: uuid type: string type: array is_billable: description: The project's billable status type: boolean managers: description: The list of managers items: format: uuid type: string type: array name: description: The project's name type: string start_at: description: An UTC time indicating when the project starts format: date type: string tags: description: The list of tags items: format: uuid type: string type: array visibility: description: The project visibility for users enum: - public - private type: string required: - start_at type: object model.CreatePurchaseParams: properties: billed_at: description: The purchase billed at date format: date type: string billed_price: description: The purchase billed price type: number billing_policy: description: The purchase budget billing policy enum: - add - ignore example: add type: string name: description: The purchase name type: string paid_at: description: The purchase paid at date format: date type: string paid_price: description: The purchase paid price type: number project_id: description: The project's identifier associated to the purchase (required if task_id is empty) format: uuid type: string x-nullable: true task_id: description: The task's identifier associated to the purchase (required if project_id is empty) format: uuid type: string x-nullable: true type: object model.CreateTaskParams: properties: budget_amount: description: The task's budget amount type: number x-nullable: true budget_type: description: The task's budget type enum: - none - detailed - global - time type: string end_at: description: A date indicating when the task is supposed to end format: date type: string x-nullable: true estimated_duration: description: The task's estimated duration type: integer x-nullable: true groups: description: User group assignments items: format: uuid type: string type: array hourly_rate: description: The task's hourly rate type: number x-nullable: true hourly_rate_mode: description: The task's hourly rate mode enum: - task - group - contributor type: string x-nullable: true is_container: description: Indicate if the task is a container type: boolean name: description: The task's name type: string parent_id: description: The parent task's identifier if this task is a subtask format: uuid type: string x-nullable: true planned_duration: description: The task's planned duration type: integer x-nullable: true project_id: description: The project's identifier format: uuid type: string start_at: description: A date indicating when the task starts format: date type: string tags: description: The list of tags items: type: string type: array required: - name - project_id - start_at type: object model.Customer: properties: created_at: description: An UTC time indicating when the customer was created format: date-time type: string id: description: The customer's identifier format: uuid type: string is_active: description: Indicates if the customer is active type: boolean managers: description: The list of managers associated to the customer items: format: uuid type: string type: array name: description: The customer's name type: string updated_at: description: An UTC time indicating when the customer was updated format: date-time type: string type: object model.Customers: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Customer' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.Declaration: properties: created_at: description: An UTC time indicating when the declaration object was created format: date-time type: string date: description: The declaration date format: date type: string description: description: The description of the declaration maxLength: 256 type: string x-nullable: true duration: description: The duration of the declaration in seconds type: integer edited_by: description: The identifier of the last user editing the duration format: uuid type: string hourly_cost: description: The hourly cost of the user when the declaration was created type: number x-nullable: true id: description: The declaration's identifier format: uuid type: string task_id: description: The task's identifier associated to the declaration format: uuid type: string updated_at: description: An UTC time indicating when the declaration object was updated format: date-time type: string user_id: description: The user's identifier associated to the declaration format: uuid type: string type: object model.DeleteCustomerParams: properties: id: description: The customer's identifier format: uuid type: string required: - id type: object model.DeleteDeclarationParams: properties: id: description: The declaration's identifier format: uuid type: string required: - id type: object model.DeleteDiscountParams: properties: id: description: The discount's identifier format: uuid type: string required: - id type: object model.DeleteLeavePeriodParams: properties: id: description: The leave period's identifier format: uuid type: string type: object model.DeleteProjectParams: properties: id: format: uuid type: string required: - id type: object model.DeletePurchaseParams: properties: id: description: The purchase's identifier format: uuid type: string required: - id type: object model.DeleteTaskParams: properties: id: description: The task's identifier format: uuid type: string required: - id type: object model.Discount: properties: amount: description: The discount's amount type: number created_at: description: An UTC time indicating when the discount object was created format: date-time type: string id: description: The discount's identifier format: uuid type: string name: description: The discount's name type: string project_id: description: The project's identifier associated to the discount (required if task_id is empty) format: uuid type: string x-nullable: true task_id: description: The task's identifier associated to the discount (required if project_id is empty) format: uuid type: string x-nullable: true updated_at: description: An UTC time indicating when the discount object was updated format: date-time type: string type: object model.Discounts: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Discount' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.Error: properties: error_description: type: string error_type: enum: - business_error - internal_error - invalid_argument - no_permission - not_found - rate_limits - unauthorized_access type: string type: object model.GetCustomerParams: properties: id: description: The customer's identifier format: uuid type: string required: - id type: object model.GetDiscountParams: properties: id: description: The discount's identifier format: uuid type: string required: - id type: object model.GetGroupParams: properties: id: format: uuid type: string required: - id type: object model.GetGroupsetParams: properties: id: description: The groupset's identifier format: uuid type: string type: object model.GetLeavePeriodParams: properties: id: description: The leave period's identifier format: uuid type: string required: - id type: object model.GetProjectMetricsParams: properties: project_id: format: uuid type: string type: object model.GetProjectParams: properties: id: format: uuid type: string type: object model.GetPurchaseParams: properties: id: description: The purchase's identifier format: uuid type: string required: - id type: object model.GetTagParams: properties: id: format: uuid type: string required: - id type: object model.GetTagsetParams: properties: id: description: The tagset's identifier format: uuid type: string type: object model.GetTaskParams: properties: id: description: The task's identifier format: uuid type: string required: - id type: object model.GetUserParams: properties: id: format: uuid type: string required: - id type: object model.Group: properties: created_at: description: An UTC time indicating when the groupset object was created format: date-time type: string groupset_id: format: uuid type: string id: description: The groupset's identifier format: uuid type: string manager_id: description: The groupset's manager type: string name: description: The groupset's name type: string updated_at: description: An UTC time indicating when the groupset object was updated format: date-time type: string type: object model.Groups: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Group' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.Groupset: properties: color: description: The groupset's color type: string created_at: description: An UTC time indicating when the groupset object was created format: date-time type: string id: description: The groupset's identifier format: uuid type: string is_group_unique: description: Indicate if group must be unique when attributed to user type: boolean name: description: The groupset's name type: string updated_at: description: An UTC time indicating when the groupset object was updated format: date-time type: string type: object model.Groupsets: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Groupset' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.ImportReport: properties: errors: description: List of errors encountered items: $ref: '#/definitions/model.ImporterError' type: array ok: description: Whether the import was successful type: boolean type: object model.ImporterError: properties: code: description: Error code type: string line: description: Line number where the error occurred type: integer message: description: Error message type: string type: object model.InviteUserParams: properties: email: description: The user’s email address format: email type: string group_ids: description: The user's groups items: format: uuid type: string type: array role: description: The user's role enum: - contributor - collaborator - manager - director - admin example: contributor type: string type: object model.LeavePeriod: properties: created_at: description: An UTC time indicating when the leave period object was created format: date-time type: string description: description: The description of the leave period maxLength: 128 type: string edited_by: description: The user's identifier who edited the leave period format: uuid type: string end_at: description: The end at date format: date type: string end_type: description: The end type enum: - full - am - pm type: string id: description: The leave period's identifier format: uuid type: string start_at: description: The start at date format: date type: string start_type: description: The start type enum: - full - am - pm type: string updated_at: description: An UTC time indicating when the leave period object was updated format: date-time type: string user_id: description: The user's identifier associated to the leave period format: uuid type: string type: object model.LeavePeriods: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.LeavePeriod' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.ListCustomersParams: properties: customer_ids: description: The customers' identifiers items: type: string type: array is_active: description: The customers' status type: boolean x-nullable: true limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer manager_ids: description: The list of managers associated to the customers items: type: string type: array offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.ListDeclarationsParams: properties: from: description: Limit results after or equal specified date format: date type: string limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer task_ids: description: Task's identifier items: format: uuid type: string type: array to: description: Limit results before or equal specified date format: date type: string user_ids: description: Users's identifier items: format: uuid type: string type: array required: - task_ids - user_ids type: object model.ListDiscountsParams: properties: limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer project_ids: items: type: string type: array task_ids: items: type: string type: array type: object model.ListGroupsParams: properties: group_ids: items: format: uuid type: string type: array groupset_ids: items: format: uuid type: string type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.ListGroupsetsParams: properties: groupset_ids: items: format: uuid type: string type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.ListLeavePeriodsParams: properties: from: description: Limit results after or equal specified date format: date type: string limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer to: description: Limit results before or equal specified date format: date type: string user_ids: description: Users's identifier items: format: uuid type: string type: array type: object model.ListProjectsMetricsParams: properties: project_ids: description: List of project IDs items: format: uuid type: string type: array required: - project_ids type: object model.ListProjectsParams: properties: limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer status: description: The project's status items: enum: - active - done - archived type: string type: array type: object model.ListPurchasesParams: properties: limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer project_ids: items: format: uuid type: string type: array task_ids: items: format: uuid type: string type: array type: object model.ListTagsParams: properties: limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer tag_ids: items: format: uuid type: string type: array tagset_ids: items: format: uuid type: string type: array type: object model.ListTagsetsParams: properties: limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer tagset_ids: items: format: uuid type: string type: array type: object model.ListTasksParams: properties: limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer project_ids: items: format: uuid type: string type: array task_ids: items: format: uuid type: string type: array type: object model.ListUsersParams: properties: limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.OkResponse: properties: ok: type: boolean type: object model.Project: properties: code: description: The project's code maxLength: 36 type: string x-nullable: true contributors: description: The list of contributors (must be empty when visibility="public") items: format: uuid type: string type: array created_at: description: An UTC time indicating when the project was created format: date-time type: string customer_id: description: The customer's identifier associated to the project format: uuid type: string x-nullable: true end_at: description: A date indicating when the project is supposed to end format: date type: string x-nullable: true groups: description: User group assignments items: format: uuid type: string type: array id: description: The project's identifier format: uuid type: string is_billable: description: The project's billable status type: boolean managers: description: The list of managers items: format: uuid type: string type: array name: description: The project's name type: string note: description: The project note type: string start_at: description: A date indicating when the project starts format: date type: string status: description: The project's status enum: - active - done - archived type: string tags: description: The list of tags items: format: uuid type: string type: array updated_at: description: An UTC time indicating when the project was updated format: date-time type: string visibility: description: The project visibility for users enum: - public - private type: string type: object model.ProjectMetrics: properties: budget_amount: type: number budget_spent: type: number project_id: type: string time_elapsed: type: integer time_planned: type: integer type: object model.Projects: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Project' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.Purchase: properties: billed_at: description: The purchase billed at date format: date type: string billed_price: description: The purchase billed price type: number billing_policy: description: The purchase budget billing policy enum: - add - ignore example: add type: string created_at: description: An UTC time indicating when the purchase object was created format: date-time type: string id: description: The purchase's identifier format: uuid type: string name: description: The purchase name type: string paid_at: description: The purchase paid at date format: date type: string paid_price: description: The purchase paid price type: number project_id: description: The project's identifier associated to the purchase format: uuid type: string x-nullable: true task_id: description: The task's identifier associated to the purchase format: uuid type: string x-nullable: true updated_at: description: An UTC time indicating when the purchase object was updated format: date-time type: string type: object model.Purchases: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Purchase' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.Tag: properties: created_at: description: An UTC time indicating when the tagset object was created format: date-time type: string id: description: The tagset's identifier format: uuid type: string name: description: The tagset's name type: string tagset_id: format: uuid type: string updated_at: description: An UTC time indicating when the tagset object was updated format: date-time type: string type: object model.Tags: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Tag' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.Tagset: properties: color: description: The tagset's color type: string created_at: description: An UTC time indicating when the tagset object was created format: date-time type: string id: description: The tagset's identifier format: uuid type: string is_tag_unique: description: Indicate if tag must be unique when attributed to user type: boolean name: description: The tagset's name type: string updated_at: description: An UTC time indicating when the tagset object was updated format: date-time type: string type: object model.Tagsets: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Tagset' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.Task: properties: budget_amount: description: The task's budget amount type: number x-nullable: true budget_type: description: The task's budget type enum: - none - detailed - global - time type: string completed_at: description: An UTC time indicating when the task has been completed format: date-time type: string x-nullable: true created_at: description: An UTC time indicating when the task was created format: date-time type: string end_at: description: A date indicating when the task is supposed to end format: date type: string x-nullable: true groups: description: User group assignments items: format: uuid type: string type: array hourly_rate: description: The task's hourly rate type: number x-nullable: true hourly_rate_mode: description: The task's hourly rate mode (used with budget_type=time|detailed) enum: - task - group - contributor type: string x-nullable: true id: description: The task's identifier format: uuid type: string is_container: description: Indicate if the task is a container type: boolean name: description: The task's name type: string parent_id: description: The parent task's identifier if this task is a subtask type: string x-nullable: true planned_duration: description: The task's planned duration type: integer x-nullable: true project_id: description: The project's identifier type: string start_at: description: A date indicating when the task starts format: date type: string tags: description: The list of tags items: type: string type: array updated_at: description: An UTC time indicating when the task was updated format: date-time type: string type: object model.Tasks: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.Task' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object model.UpdateCustomerParams: properties: id: description: The customer's identifier format: uuid type: string is_active: description: Indicates if the customer is active type: boolean managers: description: The list of managers associated to the customer items: format: uuid type: string type: array name: description: The customer's name type: string required: - id - name type: object model.UpdateDeclarationParams: properties: date: description: The declaration date format: date type: string description: description: The description of the declaration maxLength: 256 type: string x-nullable: true duration: description: The duration of the declaration in seconds type: integer id: description: The declaration's identifier format: uuid type: string task_id: description: The task's identifier associated to the declaration format: uuid type: string required: - date - duration - id - task_id type: object model.UpdateDiscountParams: properties: amount: description: The discount's amount type: number id: description: The discount's identifier format: uuid type: string name: description: The discount's name type: string type: object model.UpdateLeavePeriodParams: properties: delete_declaration: description: A param to delete declarations if they exist type: boolean x-nullable: true description: description: The description of the leave period maxLength: 128 type: string end_at: description: The end at date format: date type: string end_type: description: The end type enum: - full - am - pm type: string id: description: The leave period's identifier format: uuid type: string start_at: description: The start at date format: date type: string start_type: description: The start type enum: - full - am - pm type: string type: object model.UpdateProjectParams: properties: code: description: The project's code maxLength: 36 type: string x-nullable: true contributors: description: The list of contributors (must be empty when visibility="public") items: format: uuid type: string type: array customer_id: description: The customer's identifier associated to the project format: uuid type: string x-nullable: true end_at: description: An UTC time indicating when the project is supposed to end format: date type: string groups: description: User group assignments items: format: uuid type: string type: array id: description: The project's identifier format: uuid type: string is_billable: description: The project's billable status type: boolean managers: description: The list of managers items: format: uuid type: string type: array name: description: The project's name type: string start_at: description: An UTC time indicating when the project starts format: date type: string status: description: The project's status enum: - active - done - archived type: string tags: description: The list of tags items: format: uuid type: string type: array visibility: description: The project visibility for users enum: - public - private type: string required: - start_at type: object model.UpdatePurchaseParams: properties: billed_at: description: The purchase billed at date format: date type: string billed_price: description: The purchase billed price type: number billing_policy: description: The purchase budget billing policy enum: - add - ignore example: add type: string id: description: The purchase's identifier format: uuid type: string name: description: The purchase name type: string paid_at: description: The purchase paid at date format: date type: string paid_price: description: The purchase paid price type: number required: - id type: object model.UpdateTaskParams: properties: budget_amount: description: The task's budget amount type: number x-nullable: true completed_at: description: An UTC time indicating when the task has been completed format: date-time type: string x-nullable: true end_at: description: A date indicating when the task is supposed to end format: date type: string x-nullable: true groups: description: User group assignments items: format: uuid type: string type: array hourly_rate: description: The task's hourly rate type: number x-nullable: true hourly_rate_mode: description: The task's hourly rate mode enum: - task - group - contributor type: string x-nullable: true id: description: The task's identifier format: uuid type: string name: description: The task's name type: string planned_duration: description: The task's planned duration type: integer x-nullable: true start_at: description: A date indicating when the task starts format: date type: string x-nullable: true tags: description: The list of tags items: type: string type: array required: - id type: object model.User: properties: code: description: The user’s code type: string created_at: description: An UTC time indicating when the user object was created format: date-time type: string disabled_at: description: Indicate when the user has been disabled type: string email: description: The user’s email address format: email type: string groups: items: format: uuid type: string type: array hourly_cost: description: The user's hourly cost (available only for budget offer) type: number x-nullable: true hourly_rate: description: The user's hourly rate (available only for budget offer) type: number x-nullable: true id: description: The user's identifier format: uuid type: string is_disabled: description: 'DEPRECATED: Indicate if the user is disabled' type: boolean name: description: The user’s displayed name example: Jean-Didier type: string role: description: The user's role enum: - contributor - collaborator - manager - director - admin example: contributor type: string timesheet_approved_until: description: The date until which times are validated format: date type: string updated_at: description: An UTC time indicating when the user object was updated format: date-time type: string type: object model.Users: properties: count: description: The number of entries according to the filters type: integer data: items: $ref: '#/definitions/model.User' type: array limit: description: 'The maximum number of entries to return (max: 1000)' maximum: 1000 type: integer offset: description: The (zero-based) offset of the first item in the collection to return type: integer type: object info: contact: email: contact@gryzzly.io name: Gryzzly API url: http://www.swagger.io/support description: "# Using Gryzzly APIs\n\nThe Web API is a collection of HTTP RPC-style methods, all with URLs in the form `POST http://api.gryzzly.io/v1/RESSOURCE.ACTION`\n\nWhile it's not a REST API, those familiar with REST should be at home with its foundations in HTTP.\n\n## Building a request\n\nWhen sending a request to the API:\n\n* you must set the `Content-Type` header to `application/json`\n* you must have an `Authorization` header with your API key\n* you must set a payload even if empty \n* you may explicitly set the properties of an object to `null` to require its default value\n\nFor example, a request to `projects.create` might look like this:\n\n```http\nPOST /v1/projects.create\nContent-type: application/json\nAuthorization: Bearer xxxxxxxxxxxxxxxxx\n\n{\"name\":\"my project\"}\n```\n\nand `users.list` might look like this:\n\n```http\nPOST /v1/users.list\nContent-type: application/json\nAuthorization: Bearer xxxxxxxxxxxxxxxxx\n\n{}\n```\n\n## Evaluating responses\n\nA response from the API comes with a JSON object and an HTTP status code.\n\nSuccessful requests are answered with the status 200 and returned the ressource:\n\n```http\nHTTP/1.1 200 OK\nContent-Type: application/json\n\n{}\n```\n\nFailed requests are answered with a status 4xx or 5xx and returned an error:\n\n```http\nHTTP/1.1 401 OK\nContent-Type: application/json\n\n{\n \"error_type\": \"unauthorized_access\",\n \ \"error_description\": \"invalid api key\"\n}\n```\n\nThe error object is composed of:\n\n- an `error_type` containing a short machine-readable error code\n- an optional `error_description` containing additional information on the error\n\n## Authentication\n\nThe API only accepts requests made over HTTPS and requires an `Authorization` header set with an API key.\n\nYou can create and manage your API keys from [Gryzzly's Dashboard](https://app.gryzzly.io/administration/api-keys).\n\nThe syntax of the `Authorization` header follows the [RFC6750](https://datatracker.ietf.org/doc/html/rfc6750#section-2.1). It requires the `Bearer` authentication scheme followed by the API key:\n\n```\nAuthorization: Bearer xxxxxxxxxxxxxxxxx\n```\n\n## Rate limits\n\nGryzzly APIs rely on rate limits to help provide a pleasant experience. We limit our teams to 50 requests per 10 seconds, allowing short burst as well as regular stream.\n\nIf you exceed the rate limit, the response will look like this:\n\n```http\nHTTP/1.1 429 Too Many Requests\nContent-Type: application/json\n\n{\n \"error_type\": \"rate_limits\",\n \ \"error_description\": \"allowed 50 requests per 10 seconds\"\n}\n```\n" title: Swagger Gryzzly API version: "1.0" paths: /customers.create: post: consumes: - application/json operationId: CreateCustomer parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.CreateCustomerParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Customer' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Create a customer tags: - Customers /customers.delete: post: consumes: - application/json operationId: DeleteCustomer parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.DeleteCustomerParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.OkResponse' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Delete a customer tags: - Customers /customers.get: post: consumes: - application/json operationId: GetCustomer parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetCustomerParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Customer' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a customer tags: - Customers /customers.list: post: consumes: - application/json operationId: ListCustomers parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListCustomersParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Customers' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List customers tags: - Customers /customers.update: post: consumes: - application/json operationId: UpdateCustomer parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.UpdateCustomerParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Customer' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Update a customer tags: - Customers /declarations.create: post: consumes: - application/json operationId: CreateDeclaration parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.CreateDeclarationParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Declaration' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Create a declaration tags: - Declarations /declarations.delete: post: consumes: - application/json operationId: DeleteDeclaration parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.DeleteDeclarationParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Declaration' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Delete a declaration tags: - Declarations /declarations.list: post: consumes: - application/json operationId: ListDeclarations parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListDeclarationsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Declaration' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List declarations tags: - Declarations /declarations.update: post: consumes: - application/json operationId: UpdateDeclaration parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.UpdateDeclarationParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Declaration' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Update a declaration tags: - Declarations /discounts.create: post: consumes: - application/json operationId: CreateDiscount parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.CreateDiscountParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Discount' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Create a discount tags: - Discounts /discounts.delete: post: consumes: - application/json operationId: DeleteDiscount parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.DeleteDiscountParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.OkResponse' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Delete a discount tags: - Discounts /discounts.get: post: consumes: - application/json operationId: GetDiscount parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetDiscountParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Discount' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a discount tags: - Discounts /discounts.list: post: consumes: - application/json operationId: ListDiscounts parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListDiscountsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Discounts' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List discounts tags: - Discounts /discounts.update: post: consumes: - application/json operationId: UpdateDiscount parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.UpdateDiscountParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Discount' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Update a discount tags: - Discounts /groups.get: post: consumes: - application/json operationId: GetGroup parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetGroupParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Group' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a group tags: - Groups /groups.list: post: consumes: - application/json operationId: ListGroups parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListGroupsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Groups' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List groups tags: - Groups /groupsets.get: post: consumes: - application/json operationId: GetGroupset parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetGroupsetParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Groupset' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a groupset tags: - Groupsets /groupsets.list: post: consumes: - application/json operationId: ListGroupsets parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListGroupsetsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Groupsets' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List groupsets tags: - Groupsets /leavesPeriods.create: post: consumes: - application/json operationId: CreateLeavePeriod parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.CreateLeavePeriodParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.LeavePeriod' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Create a leave period tags: - LeavePeriods /leavesPeriods.delete: post: consumes: - application/json operationId: DeleteLeavePeriod parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.DeleteLeavePeriodParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.OkResponse' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Delete a leave period tags: - LeavePeriods /leavesPeriods.get: post: consumes: - application/json operationId: GetLeavePeriod parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetLeavePeriodParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.LeavePeriod' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a leave period tags: - LeavePeriods /leavesPeriods.import: post: consumes: - text/csv - application/vnd.openxmlformats-officedocument.spreadsheetml.sheet operationId: ImportLeavePeriods produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.ImportReport' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Import leaves from file tags: - LeavesPeriods /leavesPeriods.list: post: consumes: - application/json operationId: ListLeavePeriods parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListLeavePeriodsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.LeavePeriods' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List leaves periods tags: - LeavePeriods /leavesPeriods.update: post: consumes: - application/json operationId: UpdateLeavePeriod parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.UpdateLeavePeriodParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.LeavePeriod' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Update a leave period tags: - LeavePeriods /projects.create: post: consumes: - application/json operationId: CreateProject parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.CreateProjectParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Project' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Create a project tags: - Projects /projects.delete: post: consumes: - application/json description: This method will fail if their are declarations associated with the project. operationId: DeleteProject parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.DeleteProjectParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.OkResponse' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Delete a project tags: - Projects /projects.export: get: consumes: - application/json operationId: GetProjectsExportFile parameters: - description: Limit results after or equal specified date format: date in: query name: from type: string - collectionFormat: csv in: query items: type: string name: project_ids type: array - description: Limit results before or equal specified date format: date in: query name: to type: string - description: The file type enum: - csv - xlsx in: query name: type type: string produces: - application/octet-stream responses: "200": description: Export file schema: type: file default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get projects export file tags: - Export /projects.get: post: consumes: - application/json operationId: GetProject parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetProjectParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Project' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a project tags: - Projects /projects.getMetrics: post: consumes: - application/json operationId: GetProjectMetrics parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetProjectMetricsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.ProjectMetrics' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get project's metrics tags: - Projects /projects.list: post: consumes: - application/json operationId: ListProjects parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListProjectsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Projects' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List projects tags: - Projects /projects.listMetrics: post: consumes: - application/json operationId: ListProjectsMetrics parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListProjectsMetricsParams' produces: - application/json responses: "200": description: OK schema: items: $ref: '#/definitions/model.ProjectMetrics' type: array default: description: "" schema: $ref: '#/definitions/model.Error' summary: List projects metrics tags: - Projects /projects.update: post: consumes: - application/json operationId: UpdateProject parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.UpdateProjectParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Project' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Update a project tags: - Projects /purchases.create: post: consumes: - application/json operationId: CreatePurchase parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.CreatePurchaseParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Purchase' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Create a purchase tags: - Purchases /purchases.delete: post: consumes: - application/json operationId: DeletePurchase parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.DeletePurchaseParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Purchase' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Delete a purchase tags: - Purchases /purchases.get: post: consumes: - application/json operationId: GetPurchase parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetPurchaseParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Purchase' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a purchase tags: - Purchases /purchases.list: post: consumes: - application/json operationId: ListPurchases parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListPurchasesParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Purchases' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List purchases tags: - Purchases /purchases.update: post: consumes: - application/json operationId: UpdatePurchase parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.UpdatePurchaseParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Purchase' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Update a purchase tags: - Purchases /tags.get: post: consumes: - application/json operationId: GetTag parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetTagParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Tag' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a tag tags: - Tags /tags.list: post: consumes: - application/json operationId: ListTags parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListTagsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Tags' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List tags tags: - Tags /tagsets.get: post: consumes: - application/json operationId: GetTagset parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetTagsetParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Tagset' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a tagset tags: - Tagsets /tagsets.list: post: consumes: - application/json operationId: ListTagsets parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListTagsetsParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Tagsets' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List tagsets tags: - Tagsets /tasks.create: post: consumes: - application/json description: | The creation of a task is conditioned by the type of budget you want to use and its position in the project's hierarchy. ### Project hierarchy A task can be: - a root task, if is has no parent and is not a group - a group task, if `is_group` is true - a subtask, if `parent_id` is set For exemple, a project might look like this: ``` My project | +--A root task | +--A group task | +---A subtask ``` ### Budget type There are 4 types of budget, each with different requirements. #### None If you don't need to follow your budget, this is the way to go. Your task only requires a name, the ID of the project and a start date. You can add the `planned_duration` property if you want additional information and graphics in the dashboard. #### Detailed *Only available with the budget offer.* The detailed budget allows you to track profits for tasks sold with a fixed budget and a fixed amount of time. For root task and subtask, it requires 2 of the following properties: - `planned_duration`, the duration planned - `budget_amount`, the estimated budget - `hourly_rate`, the rate at which 1 hour is budgeted #### Global *Only available with the budget offer.* The global budget allows you to track profits for tasks sold with a fixed budget and a dynamic amount of time or a dynamic rate. The following fields are required when creating a root task: - `budget_amount` - `hourly_rate_mode: task | contributor` - `hourly_rate` if `hourly_rate_mode == task` The following fields are required when creating a group task: - `budget_amount` - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == group` The following fields are required when creating a subtask: - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == task` Additional rules apply to the `hourly_rate_mode` in a subtask: - if the parent's `hourly_rate_mode` is equal to `contributor`, it must be set to `contributor` - if the parent's `hourly_rate_mode` is equal to `group`, it must be set to `group` - if the parent's `hourly_rate_mode` is equal to `task`, it can either be `task` or `contributor` #### Time *Only available with the budget offer.* The time budget allows you to track profits for tasks sold with a dynamic budget. The following fields are required when creating a root task: - `hourly_rate_mode: task | contributor` - `hourly_rate` if `hourly_rate_mode == task` The following fields are required when creating a group task: - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == group` The following fields are required when creating a subtask: - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == task` Additional rules apply to the `hourly_rate_mode` in a subtask: - if the parent's `hourly_rate_mode` is equal to `contributor`, it must be set to `contributor` - if the parent's `hourly_rate_mode` is equal to `group`, it must be set to `group` - if the parent's `hourly_rate_mode` is equal to `task`, it can either be `task` or `contributor` operationId: CreateTask parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.CreateTaskParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Task' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Create a task tags: - Tasks /tasks.delete: post: consumes: - application/json description: This method will fail if their are declarations associated with the task. operationId: DeleteTask parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.DeleteTaskParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.OkResponse' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Delete a task tags: - Tasks /tasks.get: post: consumes: - application/json operationId: GetTask parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetTaskParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Task' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a task tags: - Tasks /tasks.list: post: consumes: - application/json operationId: ListTasks parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListTasksParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Tasks' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List tasks tags: - Tasks /tasks.update: post: consumes: - application/json description: | The update of a task is conditioned by the type of budget you want to use and its position in the project's hierarchy. You can consult the documentation on how to create a task for detailed information. ### Budget type There are 4 types of budget, each with different requirements. #### None No additional field is required. But you can add the `planned_duration` property if you want additional information and graphics in the dashboard. ### Detailed For root task and subtask, it requires 2 of the following properties: - `planned_duration`, the duration planned - `budget_amount`, the estimated budget - `hourly_rate`, the rate at which 1 hour is budgeted #### Global *Only available with the budget offer.* The following fields are required when creating a root task: - `budget_amount` - `hourly_rate_mode: task | contributor` - `hourly_rate` if `hourly_rate_mode == task` The following fields are required when creating a group task: - `budget_amount` - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == group` The following fields are required when creating a subtask: - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == task` Additional rules apply to the `hourly_rate_mode` in a subtask: - if the parent's `hourly_rate_mode` is equal to `contributor`, it must be set to `contributor` - if the parent's `hourly_rate_mode` is equal to `group`, it must be set to `group` - if the parent's `hourly_rate_mode` is equal to `task`, it can either be `task` or `contributor` ### Time *Only available with the budget offer.* The following fields are required when creating a root task: - `budget_amount` - `hourly_rate_mode: task | contributor` - `hourly_rate` if `hourly_rate_mode == task` The following fields are required when creating a group task: - `budget_amount` - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == group` The following fields are required when creating a subtask: - `hourly_rate_mode: task | contributor | group` - `hourly_rate` if `hourly_rate_mode == task` Additional rules apply to the `hourly_rate_mode` in a subtask: - if the parent's `hourly_rate_mode` is equal to `contributor`, it must be set to `contributor` - if the parent's `hourly_rate_mode` is equal to `group`, it must be set to `group` - if the parent's `hourly_rate_mode` is equal to `task`, it can either be `task` or `contributor` operationId: UpdateTask parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.UpdateTaskParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Task' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Update a task tags: - Tasks /timesAndLeaves.export: get: consumes: - application/json operationId: GetDeclarationsAndLeavesExportFile parameters: - description: Limit results after or equal specified date format: date in: query name: from type: string - description: Limit results before or equal specified date format: date in: query name: to type: string - description: The file type enum: - 0 - 1 in: query name: type type: integer x-enum-varnames: - ExportFilterTypeCSV - ExportFilterTypeXLSX produces: - application/octet-stream responses: "200": description: Export file schema: type: file default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get declaration and leaves export file tags: - Export /users.get: post: consumes: - application/json operationId: GetUser parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.GetUserParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.User' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Get a user tags: - Users /users.invite: post: consumes: - application/json operationId: InviteUser parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.InviteUserParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.User' default: description: "" schema: $ref: '#/definitions/model.Error' summary: Invite a user tags: - Users /users.list: post: consumes: - application/json operationId: ListUsers parameters: - description: payload in: body name: params schema: $ref: '#/definitions/model.ListUsersParams' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/model.Users' default: description: "" schema: $ref: '#/definitions/model.Error' summary: List users tags: - Users swagger: "2.0"