diff --git a/Resources/harvest-openapi.yaml b/Resources/harvest-openapi.yaml index ad4da4c..ff98e31 100644 --- a/Resources/harvest-openapi.yaml +++ b/Resources/harvest-openapi.yaml @@ -2519,6 +2519,12 @@ paths: required: false in: query type: integer + - + name: task_id + description: 'Only return time entries belonging to the task with the given ID.' + required: false + in: query + type: integer - name: is_billed description: 'Pass true to only return time entries that have been invoiced and false to return time entries that have not been invoiced.' @@ -4315,6 +4321,8 @@ paths: responses: 200: description: 'Retrieve the currently authenticated user' + schema: + $ref: '#/definitions/User' default: description: 'error payload' schema: @@ -4458,6 +4466,465 @@ paths: description: 'error payload' schema: $ref: '#/definitions/Error' + /reports/expenses/clients: + get: + summary: 'Clients Report' + operationId: clientsReport + description: '' + externalDocs: + description: 'Clients Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/expense-reports/#clients-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on expenses with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on expenses with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Clients Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/expenses/projects: + get: + summary: 'Projects Report' + operationId: projectsReport + description: '' + externalDocs: + description: 'Projects Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/expense-reports/#projects-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on expenses with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on expenses with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Projects Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/expenses/categories: + get: + summary: 'Expense Categories Report' + operationId: expenseCategoriesReport + description: '' + externalDocs: + description: 'Expense Categories Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/expense-reports/#expense-categories-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on expenses with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on expenses with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Expense Categories Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/expenses/team: + get: + summary: 'Team Report' + operationId: teamReport + description: '' + externalDocs: + description: 'Team Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/expense-reports/#team-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on expenses with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on expenses with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Team Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/uninvoiced: + get: + summary: 'Uninvoiced Report' + operationId: uninvoicedReport + description: "The response contains an object with a results property that contains an array of up to per_page results. Each entry in the array is a separate result object. If no more results are available, the resulting array will be empty. Several additional pagination properties are included in the response to simplify paginating your results.\n\nNote: Each request requires both the from and to parameters to be supplied in the URL’s query string. The timeframe supplied cannot exceed 1 year (365 days)." + externalDocs: + description: 'Uninvoiced Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/uninvoiced-report/#uninvoiced-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on time entries and expenses with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on time entries and expenses with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Uninvoiced Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/time/clients: + get: + summary: 'Clients Report' + operationId: clientsReport + description: '' + externalDocs: + description: 'Clients Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/time-reports/#clients-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on time entries with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on time entries with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Clients Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/time/projects: + get: + summary: 'Projects Report' + operationId: projectsReport + description: '' + externalDocs: + description: 'Projects Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/time-reports/#projects-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on time entries with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on time entries with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Projects Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/time/tasks: + get: + summary: 'Tasks Report' + operationId: tasksReport + description: '' + externalDocs: + description: 'Tasks Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/time-reports/#tasks-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on time entries with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on time entries with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Tasks Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/time/team: + get: + summary: 'Team Report' + operationId: teamReport + description: '' + externalDocs: + description: 'Team Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/time-reports/#team-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + from: + type: string + description: 'Only report on time entries with a spent_date on or after the given date.' + format: date + to: + type: string + description: 'Only report on time entries with a spent_date on or before the given date.' + format: date + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + required: + - from + - to + responses: + 200: + description: 'Team Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' + /reports/project_budget: + get: + summary: 'Project Budget Report' + operationId: projectBudgetReport + description: 'The response contains an object with a results property that contains an array of up to per_page results. Each entry in the array is a separate result object. If no more results are available, the resulting array will be empty. Several additional pagination properties are included in the response to simplify paginating your results.' + externalDocs: + description: 'Project Budget Report' + url: 'https://help.getharvest.com/api-v2/reports-api/reports/project-budget-report/#project-budget-report' + security: + - + BearerAuth: [] + AccountAuth: [] + parameters: + - + name: payload + description: 'json payload' + required: true + in: body + schema: + type: object + properties: + page: + type: integer + description: 'The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1)' + format: int32 + per_page: + type: integer + description: 'The number of records to return per page. Can range between 1 and 1000. (Default: 1000)' + format: int32 + responses: + 200: + description: 'Project Budget Report' + default: + description: 'error payload' + schema: + $ref: '#/definitions/Error' definitions: Contact: type: object @@ -5402,6 +5869,10 @@ definitions: type: number description: 'Number of (decimal time) hours tracked in this time entry.' format: float + rounded_hours: + type: number + description: 'Number of (decimal time) hours tracked in this time entry used in summary reports and invoices. This value is rounded according to the Time Rounding setting in your Preferences.' + format: float notes: type: string description: 'Notes attached to the time entry.' @@ -5870,6 +6341,47 @@ definitions: type: string description: 'Date and time the user was last updated.' format: date-time + Result: + type: object + externalDocs: + description: result + url: 'https://help.getharvest.com/api-v2/reports-api/reports/project-budget-report/#the-result-object' + properties: + client_id: + type: integer + description: 'The ID of the client associated with this project.' + format: int32 + client_name: + type: string + description: 'The name of the client associated with this project.' + project_id: + type: integer + description: 'The ID of the project.' + format: int32 + project_name: + type: string + description: 'The name of the project.' + budget_is_monthly: + type: boolean + description: 'Whether the budget is reset every month.' + budget_by: + type: string + description: 'The method by which the project is budgeted. Options: project (Hours Per Project), project_cost (Total Project Fees), task (Hours Per Task), task_fees (Fees Per Task), person (Hours Per Person), none (No Budget).' + is_active: + type: boolean + description: 'Whether the project is active or archived.' + budget: + type: number + description: 'The budget in hours or money for the project when budgeting by time. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission.' + format: float + budget_spent: + type: number + description: 'The total hours or money spent against the project’s budget. If Time Rounding is turned on, the hours will be rounded according to your settings. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission.' + format: float + budget_remaining: + type: number + description: 'The total hours or money remaining in the project’s budget. If Time Rounding is turned on, the hours will be rounded according to your settings. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission.' + format: float Contacts: type: object required: @@ -6806,6 +7318,42 @@ definitions: format: int64 links: $ref: '#/definitions/PaginationLinks' + Results: + type: object + required: + - results + - per_page + - total_pages + - total_entries + - next_page + - previous_page + - page + - links + properties: + results: + type: array + items: + $ref: '#/definitions/Result' + per_page: + type: integer + format: int64 + total_pages: + type: integer + format: int64 + total_entries: + type: integer + format: int64 + next_page: + type: integer + format: int64 + previous_page: + type: integer + format: int64 + page: + type: integer + format: int64 + links: + $ref: '#/definitions/PaginationLinks' Error: type: object properties: diff --git a/generated/Client.php b/generated/Client.php index 3dd434b..3a90801 100644 --- a/generated/Client.php +++ b/generated/Client.php @@ -791,6 +791,7 @@ public function updateTask(string $taskId, \JoliCode\Harvest\Api\Model\TasksTask * @var int $user_id Only return time entries belonging to the user with the given ID. * @var int $client_id Only return time entries belonging to the client with the given ID. * @var int $project_id Only return time entries belonging to the project with the given ID. + * @var int $task_id Only return time entries belonging to the task with the given ID. * @var bool $is_billed Pass true to only return time entries that have been invoiced and false to return time entries that have not been invoiced. * @var bool $is_running Pass true to only return running time entries and false to return non-running time entries. * @var string $updated_since Only return time entries that have been updated since the given date and time. Use the ISO 8601 Format. @@ -1385,7 +1386,7 @@ public function createUser(\JoliCode\Harvest\Api\Model\UsersPostBody $payload, s /** * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) * - * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + * @return null|\JoliCode\Harvest\Api\Model\User|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface */ public function retrieveTheCurrentlyAuthenticatedUser(string $fetch = self::FETCH_OBJECT) { @@ -1428,6 +1429,92 @@ public function updateUser(string $userId, \JoliCode\Harvest\Api\Model\UsersUser { return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\UpdateUser($userId, $payload), $fetch); } + /** + * + * + * @param \JoliCode\Harvest\Api\Model\ReportsTimeClientsGetBody $payload json payload + * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) + * + * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + */ + public function clientsReport(\JoliCode\Harvest\Api\Model\ReportsTimeClientsGetBody $payload, string $fetch = self::FETCH_OBJECT) + { + return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\ClientsReport($payload), $fetch); + } + /** + * + * + * @param \JoliCode\Harvest\Api\Model\ReportsTimeProjectsGetBody $payload json payload + * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) + * + * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + */ + public function projectsReport(\JoliCode\Harvest\Api\Model\ReportsTimeProjectsGetBody $payload, string $fetch = self::FETCH_OBJECT) + { + return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\ProjectsReport($payload), $fetch); + } + /** + * + * + * @param \JoliCode\Harvest\Api\Model\ReportsExpensesCategoriesGetBody $payload json payload + * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) + * + * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + */ + public function expenseCategoriesReport(\JoliCode\Harvest\Api\Model\ReportsExpensesCategoriesGetBody $payload, string $fetch = self::FETCH_OBJECT) + { + return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\ExpenseCategoriesReport($payload), $fetch); + } + /** + * + * + * @param \JoliCode\Harvest\Api\Model\ReportsTimeTeamGetBody $payload json payload + * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) + * + * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + */ + public function teamReport(\JoliCode\Harvest\Api\Model\ReportsTimeTeamGetBody $payload, string $fetch = self::FETCH_OBJECT) + { + return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\TeamReport($payload), $fetch); + } + /** + * The response contains an object with a results property that contains an array of up to per_page results. Each entry in the array is a separate result object. If no more results are available, the resulting array will be empty. Several additional pagination properties are included in the response to simplify paginating your results. + + Note: Each request requires both the from and to parameters to be supplied in the URL’s query string. The timeframe supplied cannot exceed 1 year (365 days). + * + * @param \JoliCode\Harvest\Api\Model\ReportsUninvoicedGetBody $payload json payload + * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) + * + * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + */ + public function uninvoicedReport(\JoliCode\Harvest\Api\Model\ReportsUninvoicedGetBody $payload, string $fetch = self::FETCH_OBJECT) + { + return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\UninvoicedReport($payload), $fetch); + } + /** + * + * + * @param \JoliCode\Harvest\Api\Model\ReportsTimeTasksGetBody $payload json payload + * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) + * + * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + */ + public function tasksReport(\JoliCode\Harvest\Api\Model\ReportsTimeTasksGetBody $payload, string $fetch = self::FETCH_OBJECT) + { + return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\TasksReport($payload), $fetch); + } + /** + * The response contains an object with a results property that contains an array of up to per_page results. Each entry in the array is a separate result object. If no more results are available, the resulting array will be empty. Several additional pagination properties are included in the response to simplify paginating your results. + * + * @param \JoliCode\Harvest\Api\Model\ReportsProjectBudgetGetBody $payload json payload + * @param string $fetch Fetch mode to use (can be OBJECT or RESPONSE) + * + * @return null|\JoliCode\Harvest\Api\Model\Error|\Psr\Http\Message\ResponseInterface + */ + public function projectBudgetReport(\JoliCode\Harvest\Api\Model\ReportsProjectBudgetGetBody $payload, string $fetch = self::FETCH_OBJECT) + { + return $this->executePsr7Endpoint(new \JoliCode\Harvest\Api\Endpoint\ProjectBudgetReport($payload), $fetch); + } public static function create($httpClient = null, \Jane\OpenApiRuntime\Client\Authentication $authentication = null) { if (null === $httpClient) { diff --git a/generated/Endpoint/ClientsReport.php b/generated/Endpoint/ClientsReport.php new file mode 100644 index 0000000..5a37aee --- /dev/null +++ b/generated/Endpoint/ClientsReport.php @@ -0,0 +1,42 @@ +body = $payload; + } + use \Jane\OpenApiRuntime\Client\Psr7EndpointTrait; + public function getMethod() : string + { + return 'GET'; + } + public function getUri() : string + { + return '/reports/time/clients'; + } + public function getBody(\Symfony\Component\Serializer\SerializerInterface $serializer, $streamFactory = null) : array + { + return $this->getSerializedBody($serializer); + } + /** + * {@inheritdoc} + * + * + * @return null|\JoliCode\Harvest\Api\Model\Error + */ + protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) + { + if (200 === $status) { + return null; + } + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); + } +} \ No newline at end of file diff --git a/generated/Endpoint/ExpenseCategoriesReport.php b/generated/Endpoint/ExpenseCategoriesReport.php new file mode 100644 index 0000000..147bf05 --- /dev/null +++ b/generated/Endpoint/ExpenseCategoriesReport.php @@ -0,0 +1,42 @@ +body = $payload; + } + use \Jane\OpenApiRuntime\Client\Psr7EndpointTrait; + public function getMethod() : string + { + return 'GET'; + } + public function getUri() : string + { + return '/reports/expenses/categories'; + } + public function getBody(\Symfony\Component\Serializer\SerializerInterface $serializer, $streamFactory = null) : array + { + return $this->getSerializedBody($serializer); + } + /** + * {@inheritdoc} + * + * + * @return null|\JoliCode\Harvest\Api\Model\Error + */ + protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) + { + if (200 === $status) { + return null; + } + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); + } +} \ No newline at end of file diff --git a/generated/Endpoint/ListTimeEntries.php b/generated/Endpoint/ListTimeEntries.php index 9e75618..a99f927 100644 --- a/generated/Endpoint/ListTimeEntries.php +++ b/generated/Endpoint/ListTimeEntries.php @@ -13,6 +13,7 @@ class ListTimeEntries extends \Jane\OpenApiRuntime\Client\BaseEndpoint implement * @var int $user_id Only return time entries belonging to the user with the given ID. * @var int $client_id Only return time entries belonging to the client with the given ID. * @var int $project_id Only return time entries belonging to the project with the given ID. + * @var int $task_id Only return time entries belonging to the task with the given ID. * @var bool $is_billed Pass true to only return time entries that have been invoiced and false to return time entries that have not been invoiced. * @var bool $is_running Pass true to only return running time entries and false to return non-running time entries. * @var string $updated_since Only return time entries that have been updated since the given date and time. Use the ISO 8601 Format. @@ -42,12 +43,13 @@ public function getBody(\Symfony\Component\Serializer\SerializerInterface $seria protected function getQueryOptionsResolver() : \Symfony\Component\OptionsResolver\OptionsResolver { $optionsResolver = parent::getQueryOptionsResolver(); - $optionsResolver->setDefined(array('user_id', 'client_id', 'project_id', 'is_billed', 'is_running', 'updated_since', 'from', 'to', 'page', 'per_page')); + $optionsResolver->setDefined(array('user_id', 'client_id', 'project_id', 'task_id', 'is_billed', 'is_running', 'updated_since', 'from', 'to', 'page', 'per_page')); $optionsResolver->setRequired(array()); $optionsResolver->setDefaults(array()); $optionsResolver->setAllowedTypes('user_id', array('int')); $optionsResolver->setAllowedTypes('client_id', array('int')); $optionsResolver->setAllowedTypes('project_id', array('int')); + $optionsResolver->setAllowedTypes('task_id', array('int')); $optionsResolver->setAllowedTypes('is_billed', array('bool')); $optionsResolver->setAllowedTypes('is_running', array('bool')); $optionsResolver->setAllowedTypes('updated_since', array('string')); diff --git a/generated/Endpoint/ProjectBudgetReport.php b/generated/Endpoint/ProjectBudgetReport.php new file mode 100644 index 0000000..8cc2621 --- /dev/null +++ b/generated/Endpoint/ProjectBudgetReport.php @@ -0,0 +1,42 @@ +body = $payload; + } + use \Jane\OpenApiRuntime\Client\Psr7EndpointTrait; + public function getMethod() : string + { + return 'GET'; + } + public function getUri() : string + { + return '/reports/project_budget'; + } + public function getBody(\Symfony\Component\Serializer\SerializerInterface $serializer, $streamFactory = null) : array + { + return $this->getSerializedBody($serializer); + } + /** + * {@inheritdoc} + * + * + * @return null|\JoliCode\Harvest\Api\Model\Error + */ + protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) + { + if (200 === $status) { + return null; + } + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); + } +} \ No newline at end of file diff --git a/generated/Endpoint/ProjectsReport.php b/generated/Endpoint/ProjectsReport.php new file mode 100644 index 0000000..5cba87a --- /dev/null +++ b/generated/Endpoint/ProjectsReport.php @@ -0,0 +1,42 @@ +body = $payload; + } + use \Jane\OpenApiRuntime\Client\Psr7EndpointTrait; + public function getMethod() : string + { + return 'GET'; + } + public function getUri() : string + { + return '/reports/time/projects'; + } + public function getBody(\Symfony\Component\Serializer\SerializerInterface $serializer, $streamFactory = null) : array + { + return $this->getSerializedBody($serializer); + } + /** + * {@inheritdoc} + * + * + * @return null|\JoliCode\Harvest\Api\Model\Error + */ + protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) + { + if (200 === $status) { + return null; + } + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); + } +} \ No newline at end of file diff --git a/generated/Endpoint/RetrieveTheCurrentlyAuthenticatedUser.php b/generated/Endpoint/RetrieveTheCurrentlyAuthenticatedUser.php index c6072b6..e734196 100644 --- a/generated/Endpoint/RetrieveTheCurrentlyAuthenticatedUser.php +++ b/generated/Endpoint/RetrieveTheCurrentlyAuthenticatedUser.php @@ -21,12 +21,12 @@ public function getBody(\Symfony\Component\Serializer\SerializerInterface $seria * {@inheritdoc} * * - * @return null|\JoliCode\Harvest\Api\Model\Error + * @return null|\JoliCode\Harvest\Api\Model\User|\JoliCode\Harvest\Api\Model\Error */ protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) { if (200 === $status) { - return null; + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\User', 'json'); } return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); } diff --git a/generated/Endpoint/TasksReport.php b/generated/Endpoint/TasksReport.php new file mode 100644 index 0000000..2250b21 --- /dev/null +++ b/generated/Endpoint/TasksReport.php @@ -0,0 +1,42 @@ +body = $payload; + } + use \Jane\OpenApiRuntime\Client\Psr7EndpointTrait; + public function getMethod() : string + { + return 'GET'; + } + public function getUri() : string + { + return '/reports/time/tasks'; + } + public function getBody(\Symfony\Component\Serializer\SerializerInterface $serializer, $streamFactory = null) : array + { + return $this->getSerializedBody($serializer); + } + /** + * {@inheritdoc} + * + * + * @return null|\JoliCode\Harvest\Api\Model\Error + */ + protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) + { + if (200 === $status) { + return null; + } + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); + } +} \ No newline at end of file diff --git a/generated/Endpoint/TeamReport.php b/generated/Endpoint/TeamReport.php new file mode 100644 index 0000000..dd0f98d --- /dev/null +++ b/generated/Endpoint/TeamReport.php @@ -0,0 +1,42 @@ +body = $payload; + } + use \Jane\OpenApiRuntime\Client\Psr7EndpointTrait; + public function getMethod() : string + { + return 'GET'; + } + public function getUri() : string + { + return '/reports/time/team'; + } + public function getBody(\Symfony\Component\Serializer\SerializerInterface $serializer, $streamFactory = null) : array + { + return $this->getSerializedBody($serializer); + } + /** + * {@inheritdoc} + * + * + * @return null|\JoliCode\Harvest\Api\Model\Error + */ + protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) + { + if (200 === $status) { + return null; + } + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); + } +} \ No newline at end of file diff --git a/generated/Endpoint/UninvoicedReport.php b/generated/Endpoint/UninvoicedReport.php new file mode 100644 index 0000000..b0b4fd5 --- /dev/null +++ b/generated/Endpoint/UninvoicedReport.php @@ -0,0 +1,44 @@ +body = $payload; + } + use \Jane\OpenApiRuntime\Client\Psr7EndpointTrait; + public function getMethod() : string + { + return 'GET'; + } + public function getUri() : string + { + return '/reports/uninvoiced'; + } + public function getBody(\Symfony\Component\Serializer\SerializerInterface $serializer, $streamFactory = null) : array + { + return $this->getSerializedBody($serializer); + } + /** + * {@inheritdoc} + * + * + * @return null|\JoliCode\Harvest\Api\Model\Error + */ + protected function transformResponseBody(string $body, int $status, \Symfony\Component\Serializer\SerializerInterface $serializer, ?string $contentType) + { + if (200 === $status) { + return null; + } + return $serializer->deserialize($body, 'JoliCode\\Harvest\\Api\\Model\\Error', 'json'); + } +} \ No newline at end of file diff --git a/generated/Model/ReportsExpensesCategoriesGetBody.php b/generated/Model/ReportsExpensesCategoriesGetBody.php new file mode 100644 index 0000000..9ec1579 --- /dev/null +++ b/generated/Model/ReportsExpensesCategoriesGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on expenses with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsExpensesClientsGetBody.php b/generated/Model/ReportsExpensesClientsGetBody.php new file mode 100644 index 0000000..a7cb6de --- /dev/null +++ b/generated/Model/ReportsExpensesClientsGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on expenses with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsExpensesProjectsGetBody.php b/generated/Model/ReportsExpensesProjectsGetBody.php new file mode 100644 index 0000000..74e6d5c --- /dev/null +++ b/generated/Model/ReportsExpensesProjectsGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on expenses with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsExpensesTeamGetBody.php b/generated/Model/ReportsExpensesTeamGetBody.php new file mode 100644 index 0000000..e259986 --- /dev/null +++ b/generated/Model/ReportsExpensesTeamGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on expenses with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on expenses with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsProjectBudgetGetBody.php b/generated/Model/ReportsProjectBudgetGetBody.php new file mode 100644 index 0000000..cf57d66 --- /dev/null +++ b/generated/Model/ReportsProjectBudgetGetBody.php @@ -0,0 +1,61 @@ +page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsTimeClientsGetBody.php b/generated/Model/ReportsTimeClientsGetBody.php new file mode 100644 index 0000000..c531080 --- /dev/null +++ b/generated/Model/ReportsTimeClientsGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on time entries with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsTimeProjectsGetBody.php b/generated/Model/ReportsTimeProjectsGetBody.php new file mode 100644 index 0000000..7e06dc7 --- /dev/null +++ b/generated/Model/ReportsTimeProjectsGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on time entries with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsTimeTasksGetBody.php b/generated/Model/ReportsTimeTasksGetBody.php new file mode 100644 index 0000000..0a672be --- /dev/null +++ b/generated/Model/ReportsTimeTasksGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on time entries with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsTimeTeamGetBody.php b/generated/Model/ReportsTimeTeamGetBody.php new file mode 100644 index 0000000..752d3a2 --- /dev/null +++ b/generated/Model/ReportsTimeTeamGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on time entries with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on time entries with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/ReportsUninvoicedGetBody.php b/generated/Model/ReportsUninvoicedGetBody.php new file mode 100644 index 0000000..353beae --- /dev/null +++ b/generated/Model/ReportsUninvoicedGetBody.php @@ -0,0 +1,115 @@ +from; + } + /** + * Only report on time entries and expenses with a spent_date on or after the given date. + * + * @param \DateTime|null $from + * + * @return self + */ + public function setFrom(?\DateTime $from) : self + { + $this->from = $from; + return $this; + } + /** + * Only report on time entries and expenses with a spent_date on or before the given date. + * + * @return \DateTime|null + */ + public function getTo() : ?\DateTime + { + return $this->to; + } + /** + * Only report on time entries and expenses with a spent_date on or before the given date. + * + * @param \DateTime|null $to + * + * @return self + */ + public function setTo(?\DateTime $to) : self + { + $this->to = $to; + return $this; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * The page number to use in pagination. For instance, if you make a list request and receive 100 records, your subsequent call can include page=2 to retrieve the next page of the list. (Default: 1) + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * The number of records to return per page. Can range between 1 and 1000. (Default: 1000) + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/Result.php b/generated/Model/Result.php new file mode 100644 index 0000000..1098cc9 --- /dev/null +++ b/generated/Model/Result.php @@ -0,0 +1,277 @@ +clientId; + } + /** + * The ID of the client associated with this project. + * + * @param int|null $clientId + * + * @return self + */ + public function setClientId(?int $clientId) : self + { + $this->clientId = $clientId; + return $this; + } + /** + * The name of the client associated with this project. + * + * @return string|null + */ + public function getClientName() : ?string + { + return $this->clientName; + } + /** + * The name of the client associated with this project. + * + * @param string|null $clientName + * + * @return self + */ + public function setClientName(?string $clientName) : self + { + $this->clientName = $clientName; + return $this; + } + /** + * The ID of the project. + * + * @return int|null + */ + public function getProjectId() : ?int + { + return $this->projectId; + } + /** + * The ID of the project. + * + * @param int|null $projectId + * + * @return self + */ + public function setProjectId(?int $projectId) : self + { + $this->projectId = $projectId; + return $this; + } + /** + * The name of the project. + * + * @return string|null + */ + public function getProjectName() : ?string + { + return $this->projectName; + } + /** + * The name of the project. + * + * @param string|null $projectName + * + * @return self + */ + public function setProjectName(?string $projectName) : self + { + $this->projectName = $projectName; + return $this; + } + /** + * Whether the budget is reset every month. + * + * @return bool|null + */ + public function getBudgetIsMonthly() : ?bool + { + return $this->budgetIsMonthly; + } + /** + * Whether the budget is reset every month. + * + * @param bool|null $budgetIsMonthly + * + * @return self + */ + public function setBudgetIsMonthly(?bool $budgetIsMonthly) : self + { + $this->budgetIsMonthly = $budgetIsMonthly; + return $this; + } + /** + * The method by which the project is budgeted. Options: project (Hours Per Project), project_cost (Total Project Fees), task (Hours Per Task), task_fees (Fees Per Task), person (Hours Per Person), none (No Budget). + * + * @return string|null + */ + public function getBudgetBy() : ?string + { + return $this->budgetBy; + } + /** + * The method by which the project is budgeted. Options: project (Hours Per Project), project_cost (Total Project Fees), task (Hours Per Task), task_fees (Fees Per Task), person (Hours Per Person), none (No Budget). + * + * @param string|null $budgetBy + * + * @return self + */ + public function setBudgetBy(?string $budgetBy) : self + { + $this->budgetBy = $budgetBy; + return $this; + } + /** + * Whether the project is active or archived. + * + * @return bool|null + */ + public function getIsActive() : ?bool + { + return $this->isActive; + } + /** + * Whether the project is active or archived. + * + * @param bool|null $isActive + * + * @return self + */ + public function setIsActive(?bool $isActive) : self + { + $this->isActive = $isActive; + return $this; + } + /** + * The budget in hours or money for the project when budgeting by time. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission. + * + * @return float|null + */ + public function getBudget() : ?float + { + return $this->budget; + } + /** + * The budget in hours or money for the project when budgeting by time. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission. + * + * @param float|null $budget + * + * @return self + */ + public function setBudget(?float $budget) : self + { + $this->budget = $budget; + return $this; + } + /** + * The total hours or money spent against the project’s budget. If Time Rounding is turned on, the hours will be rounded according to your settings. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission. + * + * @return float|null + */ + public function getBudgetSpent() : ?float + { + return $this->budgetSpent; + } + /** + * The total hours or money spent against the project’s budget. If Time Rounding is turned on, the hours will be rounded according to your settings. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission. + * + * @param float|null $budgetSpent + * + * @return self + */ + public function setBudgetSpent(?float $budgetSpent) : self + { + $this->budgetSpent = $budgetSpent; + return $this; + } + /** + * The total hours or money remaining in the project’s budget. If Time Rounding is turned on, the hours will be rounded according to your settings. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission. + * + * @return float|null + */ + public function getBudgetRemaining() : ?float + { + return $this->budgetRemaining; + } + /** + * The total hours or money remaining in the project’s budget. If Time Rounding is turned on, the hours will be rounded according to your settings. If the project is budgeted by money, this value will only be visible to Administrators and Project Managers with the View billable rates and amounts permission. + * + * @param float|null $budgetRemaining + * + * @return self + */ + public function setBudgetRemaining(?float $budgetRemaining) : self + { + $this->budgetRemaining = $budgetRemaining; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/Results.php b/generated/Model/Results.php new file mode 100644 index 0000000..d887018 --- /dev/null +++ b/generated/Model/Results.php @@ -0,0 +1,223 @@ +results; + } + /** + * + * + * @param Result[]|null $results + * + * @return self + */ + public function setResults(?array $results) : self + { + $this->results = $results; + return $this; + } + /** + * + * + * @return int|null + */ + public function getPerPage() : ?int + { + return $this->perPage; + } + /** + * + * + * @param int|null $perPage + * + * @return self + */ + public function setPerPage(?int $perPage) : self + { + $this->perPage = $perPage; + return $this; + } + /** + * + * + * @return int|null + */ + public function getTotalPages() : ?int + { + return $this->totalPages; + } + /** + * + * + * @param int|null $totalPages + * + * @return self + */ + public function setTotalPages(?int $totalPages) : self + { + $this->totalPages = $totalPages; + return $this; + } + /** + * + * + * @return int|null + */ + public function getTotalEntries() : ?int + { + return $this->totalEntries; + } + /** + * + * + * @param int|null $totalEntries + * + * @return self + */ + public function setTotalEntries(?int $totalEntries) : self + { + $this->totalEntries = $totalEntries; + return $this; + } + /** + * + * + * @return int|null + */ + public function getNextPage() : ?int + { + return $this->nextPage; + } + /** + * + * + * @param int|null $nextPage + * + * @return self + */ + public function setNextPage(?int $nextPage) : self + { + $this->nextPage = $nextPage; + return $this; + } + /** + * + * + * @return int|null + */ + public function getPreviousPage() : ?int + { + return $this->previousPage; + } + /** + * + * + * @param int|null $previousPage + * + * @return self + */ + public function setPreviousPage(?int $previousPage) : self + { + $this->previousPage = $previousPage; + return $this; + } + /** + * + * + * @return int|null + */ + public function getPage() : ?int + { + return $this->page; + } + /** + * + * + * @param int|null $page + * + * @return self + */ + public function setPage(?int $page) : self + { + $this->page = $page; + return $this; + } + /** + * + * + * @return PaginationLinks|null + */ + public function getLinks() : ?PaginationLinks + { + return $this->links; + } + /** + * + * + * @param PaginationLinks|null $links + * + * @return self + */ + public function setLinks(?PaginationLinks $links) : self + { + $this->links = $links; + return $this; + } +} \ No newline at end of file diff --git a/generated/Model/TimeEntry.php b/generated/Model/TimeEntry.php index c776271..e1dc824 100644 --- a/generated/Model/TimeEntry.php +++ b/generated/Model/TimeEntry.php @@ -70,6 +70,12 @@ class TimeEntry * @var float|null */ protected $hours; + /** + * Number of (decimal time) hours tracked in this time entry used in summary reports and invoices. This value is rounded according to the Time Rounding setting in your Preferences. + * + * @var float|null + */ + protected $roundedHours; /** * Notes attached to the time entry. * @@ -391,6 +397,27 @@ public function setHours(?float $hours) : self $this->hours = $hours; return $this; } + /** + * Number of (decimal time) hours tracked in this time entry used in summary reports and invoices. This value is rounded according to the Time Rounding setting in your Preferences. + * + * @return float|null + */ + public function getRoundedHours() : ?float + { + return $this->roundedHours; + } + /** + * Number of (decimal time) hours tracked in this time entry used in summary reports and invoices. This value is rounded according to the Time Rounding setting in your Preferences. + * + * @param float|null $roundedHours + * + * @return self + */ + public function setRoundedHours(?float $roundedHours) : self + { + $this->roundedHours = $roundedHours; + return $this; + } /** * Notes attached to the time entry. * diff --git a/generated/Normalizer/JaneObjectNormalizer.php b/generated/Normalizer/JaneObjectNormalizer.php index bd757bf..1547793 100644 --- a/generated/Normalizer/JaneObjectNormalizer.php +++ b/generated/Normalizer/JaneObjectNormalizer.php @@ -12,7 +12,7 @@ class JaneObjectNormalizer implements DenormalizerInterface, NormalizerInterface { use DenormalizerAwareTrait; use NormalizerAwareTrait; - protected $normalizers = array('JoliCode\\Harvest\\Api\\Model\\Contact' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ContactClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Client' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Company' => 'JoliCode\\Harvest\\Api\\Normalizer\\CompanyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessage' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessageNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessageRecipient' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessageRecipientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicePayment' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicePaymentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicePaymentPaymentGateway' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicePaymentPaymentGatewayNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Invoice' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceEstimate' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceEstimateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceRetainer' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceRetainerNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceCreator' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceCreatorNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceLineItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceLineItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceLineItemProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceLineItemProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessage' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessageNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessageRecipient' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessageRecipientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Estimate' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateCreator' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateCreatorNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateLineItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateLineItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Expense' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseExpenseCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseExpenseCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseUser' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseUserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseReceipt' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseReceiptNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseInvoice' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseInvoiceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Task' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntry' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryUser' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryUserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryTask' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryTaskNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryExternalReference' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryExternalReferenceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryInvoice' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryInvoiceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignment' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignmentProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignmentUser' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentUserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignment' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignmentProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignmentTask' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentTaskNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Project' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Role' => 'JoliCode\\Harvest\\Api\\Normalizer\\RoleNormalizer', 'JoliCode\\Harvest\\Api\\Model\\BillableRate' => 'JoliCode\\Harvest\\Api\\Normalizer\\BillableRateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\CostRate' => 'JoliCode\\Harvest\\Api\\Normalizer\\CostRateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignment' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignmentProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignmentClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\User' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Contacts' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Clients' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Companies' => 'JoliCode\\Harvest\\Api\\Normalizer\\CompaniesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessages' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessagesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessageRecipients' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessageRecipientsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicePayments' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicePaymentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Invoices' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceLineItems' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceLineItemsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategories' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessages' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessagesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessageRecipients' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessageRecipientsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Estimates' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateLineItems' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateLineItemsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategories' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Expenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategories' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Tasks' => 'JoliCode\\Harvest\\Api\\Normalizer\\TasksNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntries' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignments' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignments' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Projects' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Roles' => 'JoliCode\\Harvest\\Api\\Normalizer\\RolesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\BillableRates' => 'JoliCode\\Harvest\\Api\\Normalizer\\BillableRatesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\CostRates' => 'JoliCode\\Harvest\\Api\\Normalizer\\CostRatesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignments' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Users' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Error' => 'JoliCode\\Harvest\\Api\\Normalizer\\ErrorNormalizer', 'JoliCode\\Harvest\\Api\\Model\\PaginationLinks' => 'JoliCode\\Harvest\\Api\\Normalizer\\PaginationLinksNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ContactsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ContactsContactIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactsContactIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ClientsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ClientsClientIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientsClientIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\CompanyPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\CompanyPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdMessagesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdMessagesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPaymentsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPaymentsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBodyLineItemsItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyLineItemsItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBodyLineItemsItemTime' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyLineItemsItemTimeNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBodyLineItemsItemExpenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyLineItemsItemExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategoriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategoriesInvoiceItemCategoryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoriesInvoiceItemCategoryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdMessagesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdMessagesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBodyLineItemsItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyLineItemsItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBodyLineItemsItemTime' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyLineItemsItemTimeNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBodyLineItemsItemExpenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyLineItemsItemExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBodyLineItemsItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyLineItemsItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBodyLineItemsItemTime' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyLineItemsItemTimeNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBodyLineItemsItemExpenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyLineItemsItemExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategoriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategoriesEstimateItemCategoryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoriesEstimateItemCategoryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpensesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpensesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpensesExpenseIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpensesExpenseIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategoriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategoriesExpenseCategoryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoriesExpenseCategoryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TasksPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TasksPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TasksTaskIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TasksTaskIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesPostBodyExternalReference' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesPostBodyExternalReferenceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesTimeEntryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesTimeEntryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesTimeEntryIdPatchBodyExternalReference' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesTimeEntryIdPatchBodyExternalReferenceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdUserAssignmentsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdUserAssignmentsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdUserAssignmentsUserAssignmentIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdUserAssignmentsUserAssignmentIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdTaskAssignmentsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdTaskAssignmentsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdTaskAssignmentsTaskAssignmentIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdTaskAssignmentsTaskAssignmentIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\RolesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\RolesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\RolesRoleIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\RolesRoleIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersUserIdBillableRatesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersUserIdBillableRatesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersUserIdCostRatesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersUserIdCostRatesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersUserIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersUserIdPatchBodyNormalizer', '\\Jane\\JsonSchemaRuntime\\Reference' => '\\Jane\\JsonSchemaRuntime\\Normalizer\\ReferenceNormalizer'), $normalizersCache = array(); + protected $normalizers = array('JoliCode\\Harvest\\Api\\Model\\Contact' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ContactClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Client' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Company' => 'JoliCode\\Harvest\\Api\\Normalizer\\CompanyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessage' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessageNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessageRecipient' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessageRecipientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicePayment' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicePaymentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicePaymentPaymentGateway' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicePaymentPaymentGatewayNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Invoice' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceEstimate' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceEstimateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceRetainer' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceRetainerNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceCreator' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceCreatorNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceLineItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceLineItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceLineItemProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceLineItemProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessage' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessageNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessageRecipient' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessageRecipientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Estimate' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateCreator' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateCreatorNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateLineItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateLineItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Expense' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseExpenseCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseExpenseCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseUser' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseUserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseReceipt' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseReceiptNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseInvoice' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseInvoiceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategory' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Task' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntry' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryUser' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryUserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryTask' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryTaskNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryExternalReference' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryExternalReferenceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntryInvoice' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntryInvoiceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignment' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignmentProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignmentUser' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentUserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignment' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignmentProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignmentTask' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentTaskNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Project' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Role' => 'JoliCode\\Harvest\\Api\\Normalizer\\RoleNormalizer', 'JoliCode\\Harvest\\Api\\Model\\BillableRate' => 'JoliCode\\Harvest\\Api\\Normalizer\\BillableRateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\CostRate' => 'JoliCode\\Harvest\\Api\\Normalizer\\CostRateNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignment' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignmentProject' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentProjectNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignmentClient' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentClientNormalizer', 'JoliCode\\Harvest\\Api\\Model\\User' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Result' => 'JoliCode\\Harvest\\Api\\Normalizer\\ResultNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Contacts' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Clients' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Companies' => 'JoliCode\\Harvest\\Api\\Normalizer\\CompaniesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessages' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessagesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceMessageRecipients' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceMessageRecipientsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicePayments' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicePaymentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Invoices' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceLineItems' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceLineItemsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategories' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessages' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessagesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateMessageRecipients' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateMessageRecipientsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Estimates' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateLineItems' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateLineItemsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategories' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Expenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategories' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Tasks' => 'JoliCode\\Harvest\\Api\\Normalizer\\TasksNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntries' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UserAssignments' => 'JoliCode\\Harvest\\Api\\Normalizer\\UserAssignmentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TaskAssignments' => 'JoliCode\\Harvest\\Api\\Normalizer\\TaskAssignmentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Projects' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Roles' => 'JoliCode\\Harvest\\Api\\Normalizer\\RolesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\BillableRates' => 'JoliCode\\Harvest\\Api\\Normalizer\\BillableRatesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\CostRates' => 'JoliCode\\Harvest\\Api\\Normalizer\\CostRatesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectAssignments' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectAssignmentsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Users' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Results' => 'JoliCode\\Harvest\\Api\\Normalizer\\ResultsNormalizer', 'JoliCode\\Harvest\\Api\\Model\\Error' => 'JoliCode\\Harvest\\Api\\Normalizer\\ErrorNormalizer', 'JoliCode\\Harvest\\Api\\Model\\PaginationLinks' => 'JoliCode\\Harvest\\Api\\Normalizer\\PaginationLinksNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ContactsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ContactsContactIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ContactsContactIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ClientsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ClientsClientIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ClientsClientIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\CompanyPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\CompanyPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdMessagesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdMessagesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPaymentsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPaymentsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBodyLineItemsItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyLineItemsItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBodyLineItemsItemTime' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyLineItemsItemTimeNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoicesInvoiceIdPatchBodyLineItemsItemExpenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoicesInvoiceIdPatchBodyLineItemsItemExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategoriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\InvoiceItemCategoriesInvoiceItemCategoryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\InvoiceItemCategoriesInvoiceItemCategoryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdMessagesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdMessagesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBodyLineItemsItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyLineItemsItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBodyLineItemsItemTime' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyLineItemsItemTimeNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesPostBodyLineItemsItemExpenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesPostBodyLineItemsItemExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBodyLineItemsItem' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyLineItemsItemNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBodyLineItemsItemTime' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyLineItemsItemTimeNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimatesEstimateIdPatchBodyLineItemsItemExpenses' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimatesEstimateIdPatchBodyLineItemsItemExpensesNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategoriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\EstimateItemCategoriesEstimateItemCategoryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\EstimateItemCategoriesEstimateItemCategoryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpensesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpensesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpensesExpenseIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpensesExpenseIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategoriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ExpenseCategoriesExpenseCategoryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ExpenseCategoriesExpenseCategoryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TasksPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TasksPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TasksTaskIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TasksTaskIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesPostBodyExternalReference' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesPostBodyExternalReferenceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesTimeEntryIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesTimeEntryIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\TimeEntriesTimeEntryIdPatchBodyExternalReference' => 'JoliCode\\Harvest\\Api\\Normalizer\\TimeEntriesTimeEntryIdPatchBodyExternalReferenceNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdUserAssignmentsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdUserAssignmentsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdUserAssignmentsUserAssignmentIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdUserAssignmentsUserAssignmentIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdTaskAssignmentsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdTaskAssignmentsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdTaskAssignmentsTaskAssignmentIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdTaskAssignmentsTaskAssignmentIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ProjectsProjectIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ProjectsProjectIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\RolesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\RolesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\RolesRoleIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\RolesRoleIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersUserIdBillableRatesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersUserIdBillableRatesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersUserIdCostRatesPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersUserIdCostRatesPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersPostBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersPostBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\UsersUserIdPatchBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\UsersUserIdPatchBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsExpensesClientsGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsExpensesClientsGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsExpensesProjectsGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsExpensesProjectsGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsExpensesCategoriesGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsExpensesCategoriesGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsExpensesTeamGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsExpensesTeamGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsUninvoicedGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsUninvoicedGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsTimeClientsGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsTimeClientsGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsTimeProjectsGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsTimeProjectsGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsTimeTasksGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsTimeTasksGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsTimeTeamGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsTimeTeamGetBodyNormalizer', 'JoliCode\\Harvest\\Api\\Model\\ReportsProjectBudgetGetBody' => 'JoliCode\\Harvest\\Api\\Normalizer\\ReportsProjectBudgetGetBodyNormalizer', '\\Jane\\JsonSchemaRuntime\\Reference' => '\\Jane\\JsonSchemaRuntime\\Normalizer\\ReferenceNormalizer'), $normalizersCache = array(); public function supportsDenormalization($data, $type, $format = null) { return array_key_exists($type, $this->normalizers); diff --git a/generated/Normalizer/ReportsExpensesCategoriesGetBodyNormalizer.php b/generated/Normalizer/ReportsExpensesCategoriesGetBodyNormalizer.php new file mode 100644 index 0000000..d2f88d6 --- /dev/null +++ b/generated/Normalizer/ReportsExpensesCategoriesGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsExpensesCategoriesGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsExpensesClientsGetBodyNormalizer.php b/generated/Normalizer/ReportsExpensesClientsGetBodyNormalizer.php new file mode 100644 index 0000000..85a7c10 --- /dev/null +++ b/generated/Normalizer/ReportsExpensesClientsGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsExpensesClientsGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsExpensesProjectsGetBodyNormalizer.php b/generated/Normalizer/ReportsExpensesProjectsGetBodyNormalizer.php new file mode 100644 index 0000000..5073627 --- /dev/null +++ b/generated/Normalizer/ReportsExpensesProjectsGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsExpensesProjectsGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsExpensesTeamGetBodyNormalizer.php b/generated/Normalizer/ReportsExpensesTeamGetBodyNormalizer.php new file mode 100644 index 0000000..0af3648 --- /dev/null +++ b/generated/Normalizer/ReportsExpensesTeamGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsExpensesTeamGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsProjectBudgetGetBodyNormalizer.php b/generated/Normalizer/ReportsProjectBudgetGetBodyNormalizer.php new file mode 100644 index 0000000..faa759b --- /dev/null +++ b/generated/Normalizer/ReportsProjectBudgetGetBodyNormalizer.php @@ -0,0 +1,68 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsProjectBudgetGetBody(); + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsTimeClientsGetBodyNormalizer.php b/generated/Normalizer/ReportsTimeClientsGetBodyNormalizer.php new file mode 100644 index 0000000..2e5451f --- /dev/null +++ b/generated/Normalizer/ReportsTimeClientsGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsTimeClientsGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsTimeProjectsGetBodyNormalizer.php b/generated/Normalizer/ReportsTimeProjectsGetBodyNormalizer.php new file mode 100644 index 0000000..65292d7 --- /dev/null +++ b/generated/Normalizer/ReportsTimeProjectsGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsTimeProjectsGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsTimeTasksGetBodyNormalizer.php b/generated/Normalizer/ReportsTimeTasksGetBodyNormalizer.php new file mode 100644 index 0000000..83c0365 --- /dev/null +++ b/generated/Normalizer/ReportsTimeTasksGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsTimeTasksGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsTimeTeamGetBodyNormalizer.php b/generated/Normalizer/ReportsTimeTeamGetBodyNormalizer.php new file mode 100644 index 0000000..48c973a --- /dev/null +++ b/generated/Normalizer/ReportsTimeTeamGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsTimeTeamGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ReportsUninvoicedGetBodyNormalizer.php b/generated/Normalizer/ReportsUninvoicedGetBodyNormalizer.php new file mode 100644 index 0000000..a604633 --- /dev/null +++ b/generated/Normalizer/ReportsUninvoicedGetBodyNormalizer.php @@ -0,0 +1,92 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\ReportsUninvoicedGetBody(); + if (property_exists($data, 'from') && $data->{'from'} !== null) { + $object->setFrom(\DateTime::createFromFormat('Y-m-d', $data->{'from'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'from') && $data->{'from'} === null) { + $object->setFrom(null); + } + if (property_exists($data, 'to') && $data->{'to'} !== null) { + $object->setTo(\DateTime::createFromFormat('Y-m-d', $data->{'to'})->setTime(0, 0, 0)); + } + elseif (property_exists($data, 'to') && $data->{'to'} === null) { + $object->setTo(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getFrom()) { + $data->{'from'} = $object->getFrom()->format('Y-m-d'); + } + else { + $data->{'from'} = null; + } + if (null !== $object->getTo()) { + $data->{'to'} = $object->getTo()->format('Y-m-d'); + } + else { + $data->{'to'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ResultNormalizer.php b/generated/Normalizer/ResultNormalizer.php new file mode 100644 index 0000000..10330c1 --- /dev/null +++ b/generated/Normalizer/ResultNormalizer.php @@ -0,0 +1,164 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\Result(); + if (property_exists($data, 'client_id') && $data->{'client_id'} !== null) { + $object->setClientId($data->{'client_id'}); + } + elseif (property_exists($data, 'client_id') && $data->{'client_id'} === null) { + $object->setClientId(null); + } + if (property_exists($data, 'client_name') && $data->{'client_name'} !== null) { + $object->setClientName($data->{'client_name'}); + } + elseif (property_exists($data, 'client_name') && $data->{'client_name'} === null) { + $object->setClientName(null); + } + if (property_exists($data, 'project_id') && $data->{'project_id'} !== null) { + $object->setProjectId($data->{'project_id'}); + } + elseif (property_exists($data, 'project_id') && $data->{'project_id'} === null) { + $object->setProjectId(null); + } + if (property_exists($data, 'project_name') && $data->{'project_name'} !== null) { + $object->setProjectName($data->{'project_name'}); + } + elseif (property_exists($data, 'project_name') && $data->{'project_name'} === null) { + $object->setProjectName(null); + } + if (property_exists($data, 'budget_is_monthly') && $data->{'budget_is_monthly'} !== null) { + $object->setBudgetIsMonthly($data->{'budget_is_monthly'}); + } + elseif (property_exists($data, 'budget_is_monthly') && $data->{'budget_is_monthly'} === null) { + $object->setBudgetIsMonthly(null); + } + if (property_exists($data, 'budget_by') && $data->{'budget_by'} !== null) { + $object->setBudgetBy($data->{'budget_by'}); + } + elseif (property_exists($data, 'budget_by') && $data->{'budget_by'} === null) { + $object->setBudgetBy(null); + } + if (property_exists($data, 'is_active') && $data->{'is_active'} !== null) { + $object->setIsActive($data->{'is_active'}); + } + elseif (property_exists($data, 'is_active') && $data->{'is_active'} === null) { + $object->setIsActive(null); + } + if (property_exists($data, 'budget') && $data->{'budget'} !== null) { + $object->setBudget($data->{'budget'}); + } + elseif (property_exists($data, 'budget') && $data->{'budget'} === null) { + $object->setBudget(null); + } + if (property_exists($data, 'budget_spent') && $data->{'budget_spent'} !== null) { + $object->setBudgetSpent($data->{'budget_spent'}); + } + elseif (property_exists($data, 'budget_spent') && $data->{'budget_spent'} === null) { + $object->setBudgetSpent(null); + } + if (property_exists($data, 'budget_remaining') && $data->{'budget_remaining'} !== null) { + $object->setBudgetRemaining($data->{'budget_remaining'}); + } + elseif (property_exists($data, 'budget_remaining') && $data->{'budget_remaining'} === null) { + $object->setBudgetRemaining(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getClientId()) { + $data->{'client_id'} = $object->getClientId(); + } + else { + $data->{'client_id'} = null; + } + if (null !== $object->getClientName()) { + $data->{'client_name'} = $object->getClientName(); + } + else { + $data->{'client_name'} = null; + } + if (null !== $object->getProjectId()) { + $data->{'project_id'} = $object->getProjectId(); + } + else { + $data->{'project_id'} = null; + } + if (null !== $object->getProjectName()) { + $data->{'project_name'} = $object->getProjectName(); + } + else { + $data->{'project_name'} = null; + } + if (null !== $object->getBudgetIsMonthly()) { + $data->{'budget_is_monthly'} = $object->getBudgetIsMonthly(); + } + else { + $data->{'budget_is_monthly'} = null; + } + if (null !== $object->getBudgetBy()) { + $data->{'budget_by'} = $object->getBudgetBy(); + } + else { + $data->{'budget_by'} = null; + } + if (null !== $object->getIsActive()) { + $data->{'is_active'} = $object->getIsActive(); + } + else { + $data->{'is_active'} = null; + } + if (null !== $object->getBudget()) { + $data->{'budget'} = $object->getBudget(); + } + else { + $data->{'budget'} = null; + } + if (null !== $object->getBudgetSpent()) { + $data->{'budget_spent'} = $object->getBudgetSpent(); + } + else { + $data->{'budget_spent'} = null; + } + if (null !== $object->getBudgetRemaining()) { + $data->{'budget_remaining'} = $object->getBudgetRemaining(); + } + else { + $data->{'budget_remaining'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/ResultsNormalizer.php b/generated/Normalizer/ResultsNormalizer.php new file mode 100644 index 0000000..3addfcd --- /dev/null +++ b/generated/Normalizer/ResultsNormalizer.php @@ -0,0 +1,148 @@ +{'$ref'})) { + return new Reference($data->{'$ref'}, $context['document-origin']); + } + if (isset($data->{'$recursiveRef'})) { + return new Reference($data->{'$recursiveRef'}, $context['document-origin']); + } + $object = new \JoliCode\Harvest\Api\Model\Results(); + if (property_exists($data, 'results') && $data->{'results'} !== null) { + $values = array(); + foreach ($data->{'results'} as $value) { + $values[] = $this->denormalizer->denormalize($value, 'JoliCode\\Harvest\\Api\\Model\\Result', 'json', $context); + } + $object->setResults($values); + } + elseif (property_exists($data, 'results') && $data->{'results'} === null) { + $object->setResults(null); + } + if (property_exists($data, 'per_page') && $data->{'per_page'} !== null) { + $object->setPerPage($data->{'per_page'}); + } + elseif (property_exists($data, 'per_page') && $data->{'per_page'} === null) { + $object->setPerPage(null); + } + if (property_exists($data, 'total_pages') && $data->{'total_pages'} !== null) { + $object->setTotalPages($data->{'total_pages'}); + } + elseif (property_exists($data, 'total_pages') && $data->{'total_pages'} === null) { + $object->setTotalPages(null); + } + if (property_exists($data, 'total_entries') && $data->{'total_entries'} !== null) { + $object->setTotalEntries($data->{'total_entries'}); + } + elseif (property_exists($data, 'total_entries') && $data->{'total_entries'} === null) { + $object->setTotalEntries(null); + } + if (property_exists($data, 'next_page') && $data->{'next_page'} !== null) { + $object->setNextPage($data->{'next_page'}); + } + elseif (property_exists($data, 'next_page') && $data->{'next_page'} === null) { + $object->setNextPage(null); + } + if (property_exists($data, 'previous_page') && $data->{'previous_page'} !== null) { + $object->setPreviousPage($data->{'previous_page'}); + } + elseif (property_exists($data, 'previous_page') && $data->{'previous_page'} === null) { + $object->setPreviousPage(null); + } + if (property_exists($data, 'page') && $data->{'page'} !== null) { + $object->setPage($data->{'page'}); + } + elseif (property_exists($data, 'page') && $data->{'page'} === null) { + $object->setPage(null); + } + if (property_exists($data, 'links') && $data->{'links'} !== null) { + $object->setLinks($this->denormalizer->denormalize($data->{'links'}, 'JoliCode\\Harvest\\Api\\Model\\PaginationLinks', 'json', $context)); + } + elseif (property_exists($data, 'links') && $data->{'links'} === null) { + $object->setLinks(null); + } + return $object; + } + public function normalize($object, $format = null, array $context = array()) + { + $data = new \stdClass(); + if (null !== $object->getResults()) { + $values = array(); + foreach ($object->getResults() as $value) { + $values[] = $this->normalizer->normalize($value, 'json', $context); + } + $data->{'results'} = $values; + } + else { + $data->{'results'} = null; + } + if (null !== $object->getPerPage()) { + $data->{'per_page'} = $object->getPerPage(); + } + else { + $data->{'per_page'} = null; + } + if (null !== $object->getTotalPages()) { + $data->{'total_pages'} = $object->getTotalPages(); + } + else { + $data->{'total_pages'} = null; + } + if (null !== $object->getTotalEntries()) { + $data->{'total_entries'} = $object->getTotalEntries(); + } + else { + $data->{'total_entries'} = null; + } + if (null !== $object->getNextPage()) { + $data->{'next_page'} = $object->getNextPage(); + } + else { + $data->{'next_page'} = null; + } + if (null !== $object->getPreviousPage()) { + $data->{'previous_page'} = $object->getPreviousPage(); + } + else { + $data->{'previous_page'} = null; + } + if (null !== $object->getPage()) { + $data->{'page'} = $object->getPage(); + } + else { + $data->{'page'} = null; + } + if (null !== $object->getLinks()) { + $data->{'links'} = $this->normalizer->normalize($object->getLinks(), 'json', $context); + } + else { + $data->{'links'} = null; + } + return $data; + } +} \ No newline at end of file diff --git a/generated/Normalizer/TimeEntryNormalizer.php b/generated/Normalizer/TimeEntryNormalizer.php index f44c9a3..58f6cbe 100644 --- a/generated/Normalizer/TimeEntryNormalizer.php +++ b/generated/Normalizer/TimeEntryNormalizer.php @@ -100,6 +100,12 @@ public function denormalize($data, $class, $format = null, array $context = arra elseif (property_exists($data, 'hours') && $data->{'hours'} === null) { $object->setHours(null); } + if (property_exists($data, 'rounded_hours') && $data->{'rounded_hours'} !== null) { + $object->setRoundedHours($data->{'rounded_hours'}); + } + elseif (property_exists($data, 'rounded_hours') && $data->{'rounded_hours'} === null) { + $object->setRoundedHours(null); + } if (property_exists($data, 'notes') && $data->{'notes'} !== null) { $object->setNotes($data->{'notes'}); } @@ -261,6 +267,12 @@ public function normalize($object, $format = null, array $context = array()) else { $data->{'hours'} = null; } + if (null !== $object->getRoundedHours()) { + $data->{'rounded_hours'} = $object->getRoundedHours(); + } + else { + $data->{'rounded_hours'} = null; + } if (null !== $object->getNotes()) { $data->{'notes'} = $object->getNotes(); } diff --git a/src/ClientFactory.php b/src/ClientFactory.php index 7b64cc9..cd00f8e 100644 --- a/src/ClientFactory.php +++ b/src/ClientFactory.php @@ -13,7 +13,6 @@ use Http\Client\Common\Plugin\AddHostPlugin; use Http\Client\Common\Plugin\AddPathPlugin; -use Http\Client\Common\Plugin\ErrorPlugin; use Http\Client\Common\Plugin\HeaderAppendPlugin; use Http\Client\Common\PluginClient; use Http\Discovery\Psr17FactoryDiscovery;