---
updatedAt: 2026-06-29T09:41:37.000Z
agentTools:
  projectIndex: https://developers.payfit.io/llms.txt
---

# List all Worked Time by contract 🇫🇷

Returns the worked time for every contract for the given pay period. This list is paginated.
\
**Required scopes**: *time:read*

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "Partner API",
    "description": "An API to let third parties communicate with PayFit",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://partner-api.payfit.com",
      "description": "The PayFit API production server"
    }
  ],
  "paths": {
    "/companies/{companyId}/contracts/time": {
      "get": {
        "operationId": "GET_contracts_worked_time",
        "summary": "List all Worked Time by contract 🇫🇷",
        "description": "Returns the worked time for every contract for the given pay period. This list is paginated.\n\\\n**Required scopes**: *time:read*",
        "tags": [
          "Contract"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "companyId",
            "schema": {
              "type": "string"
            },
            "required": true,
            "description": "The id of the company"
          },
          {
            "in": "query",
            "name": "nextPageToken",
            "required": false,
            "schema": {
              "title": "nextPageToken",
              "type": "string",
              "additionalProperties": false
            },
            "description": "The encoded pagination token"
          },
          {
            "in": "query",
            "name": "maxResults",
            "required": false,
            "schema": {
              "title": "maxResults",
              "type": "string",
              "additionalProperties": false,
              "default": "10"
            },
            "description": "Allows to define the maximum number of items to fetch at once. (Max: 50, Default: 10)"
          },
          {
            "in": "query",
            "name": "date",
            "schema": {
              "type": "string",
              "pattern": "^2\\d{3}(0[1-9]|1[0-2])$"
            },
            "required": true,
            "description": "The month to fetch the data for. This must be in the format YYYYMM, January being the month \"01\".",
            "example": 202212
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the worked time for every contract for the given pay period. Note : this endpoint is only available for French companies for now.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "contracts",
                    "meta"
                  ],
                  "properties": {
                    "contracts": {
                      "type": "array",
                      "items": {
                        "allOf": [
                          {
                            "title": "time",
                            "type": "object",
                            "description": "Absences and presence data for employees.",
                            "properties": {
                              "effectiveWorkedTime": {
                                "type": "number",
                                "nullable": true,
                                "description": "It will be available if `time:read` scope is set on the token."
                              },
                              "payedWorkedTime": {
                                "type": "number",
                                "nullable": true,
                                "description": "It will be available if `time:read` scope is set on the token."
                              },
                              "workTimeUnit": {
                                "type": "string",
                                "nullable": true,
                                "enum": [
                                  "days",
                                  "hours"
                                ],
                                "description": "It will be available if `time:read` scope is set on the token."
                              }
                            },
                            "required": [
                              "effectiveWorkedTime",
                              "payedWorkedTime",
                              "workTimeUnit"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "contractId": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "contractId"
                            ]
                          }
                        ]
                      }
                    },
                    "meta": {
                      "title": "meta",
                      "type": "object",
                      "additionalProperties": false,
                      "properties": {
                        "nextPageToken": {
                          "type": "string",
                          "nullable": true
                        },
                        "count": {
                          "type": "integer",
                          "nullable": true
                        }
                      }
                    }
                  }
                },
                "examples": {
                  "contracts": {
                    "value": {
                      "meta": {
                        "nextPageToken": "eyJsaW1pdCI6NTAsIm9mZnNldCI6NTB9",
                        "count": 2
                      },
                      "contracts": [
                        {
                          "contractId": "5b59e7b282ddef55f860d322",
                          "effectiveWorkedTime": 22,
                          "payedWorkedTime": 22,
                          "workTimeUnit": "days"
                        },
                        {
                          "contractId": "5b59e7b282ddef55f860d325",
                          "effectiveWorkedTime": 130,
                          "payedWorkedTime": 140,
                          "workTimeUnit": "hours"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "title": "error",
                  "type": "object",
                  "additionalProperties": false,
                  "properties": {
                    "error": {
                      "type": "string",
                      "description": "A human readable error"
                    },
                    "details": {
                      "oneOf": [
                        {
                          "type": "object",
                          "additionalProperties": true
                        },
                        {
                          "type": "string",
                          "additionalProperties": true
                        }
                      ]
                    },
                    "errors": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": true
                      }
                    }
                  },
                  "required": [
                    "error"
                  ]
                },
                "examples": {
                  "error": {
                    "summary": "An example of an error message",
                    "value": {
                      "code": 400,
                      "error": "Bad request",
                      "details": "Field \"id\" is required."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "title": "error",
                  "type": "object",
                  "additionalProperties": false,
                  "properties": {
                    "error": {
                      "type": "string",
                      "description": "A human readable error"
                    },
                    "details": {
                      "oneOf": [
                        {
                          "type": "object",
                          "additionalProperties": true
                        },
                        {
                          "type": "string",
                          "additionalProperties": true
                        }
                      ]
                    },
                    "errors": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": true
                      }
                    }
                  },
                  "required": [
                    "error"
                  ]
                },
                "examples": {
                  "error": {
                    "summary": "An example of an error message",
                    "value": {
                      "code": 401,
                      "error": "Unauthorized"
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "title": "error",
                  "type": "object",
                  "additionalProperties": false,
                  "properties": {
                    "error": {
                      "type": "string",
                      "description": "A human readable error"
                    },
                    "details": {
                      "oneOf": [
                        {
                          "type": "object",
                          "additionalProperties": true
                        },
                        {
                          "type": "string",
                          "additionalProperties": true
                        }
                      ]
                    },
                    "errors": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": true
                      }
                    }
                  },
                  "required": [
                    "error"
                  ]
                },
                "examples": {
                  "error": {
                    "summary": "An example of an error message",
                    "value": {
                      "code": 403,
                      "error": "Forbidden action",
                      "details": "Missing scope \"contracts:read\"."
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "title": "error",
                  "type": "object",
                  "additionalProperties": false,
                  "properties": {
                    "error": {
                      "type": "string",
                      "description": "A human readable error"
                    },
                    "details": {
                      "oneOf": [
                        {
                          "type": "object",
                          "additionalProperties": true
                        },
                        {
                          "type": "string",
                          "additionalProperties": true
                        }
                      ]
                    },
                    "errors": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": true
                      }
                    }
                  },
                  "required": [
                    "error"
                  ]
                },
                "examples": {
                  "error": {
                    "summary": "An example of an error message",
                    "value": {
                      "code": 404,
                      "error": "Ressource not found",
                      "details": "The provided id is wrong"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "partner-api-oauth": [
              "time:read"
            ]
          }
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "partner-api-oauth": {
        "type": "oauth2",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://oauth.payfit.com/authorize",
            "tokenUrl": "https://oauth.payfit.com/token",
            "scopes": {
              "contracts:read": "Allow to read contracts information",
              "collaborators:contracts:write": "Allow to create contracts on a collaborator",
              "contracts:payslips:read": "Allow to read payslips",
              "contracts:time-information:read": "Allow to read time related information of contracts",
              "pension:read": "Allow to read pension documents",
              "collaborators:read": "Read general information of collaborators.",
              "collaborators:write": "Allow to create collaborators.",
              "collaborators:contracts:read": "Read contract information of collaborators.",
              "collaborators:management:read": "Read information about organisation and management.",
              "collaborators:meal-vouchers:read": "Read meal vouchers information of collaborators.",
              "collaborators:personal:read": "Read personal data of collaborators.",
              "collaborators:social-security:read": "Read the social security identifiers of collaborators.",
              "collaborators:legal-identity:read": "Read the legal identity information of collaborators.",
              "collaborators:bank-info:read": "Allow to read the bank info of collaborators.",
              "accounting:read": "Allow to read company accounting information",
              "payment-files:read": "Allow to read company payment file information",
              "time:read": "Allow to read time data",
              "time:write": "Allow to write time data",
              "health-insurance:read": "Allow to read health insurance contracts",
              "health-insurance:write": "Allow to write health insurance contracts"
            }
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "Contract"
    }
  ]
}
```