# Archipad API

GraphQL schema of the Archipad API: queries, mutations and types.

Version: 0.1.0

> **Preview.** This API is in preview: until its version 1.0.0, it may change at any time, breaking changes included, as Semantic Versioning allows for a version 0. Check its version before you build on it, and expect to adapt.

The whole schema in SDL: https://docs.archipad.dev/apis/archipad-graphql.graphql

Queries are sent to `https://api.archipad.dev/graphql`. Every request carries an OAuth 2.0 bearer token from the Archipad identity provider: see the [authentication guide](https://docs.archipad.dev/authentication.md).

## Guides

- [Authentication](https://docs.archipad.dev/authentication.md): Get an OAuth 2.0 token from the Archipad identity provider, on behalf of a user or server to server, and call the GraphQL and REST APIs with it.
- [Pagination](https://docs.archipad.dev/apis/archipad-graphql/guides/pagination.md): Page through a list with `first` and `after`, keep the arguments of the first page, and read what the filters of a list mean.

## Queries

- [`issue`](https://docs.archipad.dev/apis/archipad-graphql/queries/issue.md): Fetches an issue that was not deleted, by its identifier.
- [`issueComment`](https://docs.archipad.dev/apis/archipad-graphql/queries/issueComment.md): Fetches a note of an issue that was not deleted, by its identifier, whatever its type: a comment, or a history entry such as a status change and its motive.
- [`project`](https://docs.archipad.dev/apis/archipad-graphql/queries/project.md): Fetches a project that was not deleted, by its identifier.
- [`projects`](https://docs.archipad.dev/apis/archipad-graphql/queries/projects.md): Lists the projects the client may reach, such as the ones of its company, by page of 50 unless `first` says otherwise. Projects that were deleted are left out; listed in a fixed order, so that paging neither skips nor repeats a project.
- [`regions`](https://docs.archipad.dev/apis/archipad-graphql/queries/regions.md): Lists the regions of the projects the client may reach, with their type, by page of 50 unless `first` says otherwise; `filter` narrows them, such as to the regions of some projects, of some types or of a person. Regions and projects that were deleted are left out; listed in a fixed order, project after project, so that paging neither skips nor repeats a region.

## Objects

- [`Issue`](https://docs.archipad.dev/apis/archipad-graphql/types/Issue.md): An issue raised on a project and pinned on one of its plans.
- [`IssueComment`](https://docs.archipad.dev/apis/archipad-graphql/types/IssueComment.md): A note of an issue: a comment, or a history entry such as a status change and its motive. `Issue.comments` lists only comments with text; the `issueComment` query returns any note.
- [`IssueConnection`](https://docs.archipad.dev/apis/archipad-graphql/types/IssueConnection.md): A page of issues, as in the GraphQL Cursor Connections Specification: `edges` carry the issues and their cursors, `pageInfo` tells whether a page follows and how to ask for it.
- [`IssueEdge`](https://docs.archipad.dev/apis/archipad-graphql/types/IssueEdge.md): One of the issues of a page, with the cursor that points at it.
- [`IssueIndexes`](https://docs.archipad.dev/apis/archipad-graphql/types/IssueIndexes.md): The numbers that identify an issue to people.
- [`IssuePhase`](https://docs.archipad.dev/apis/archipad-graphql/types/IssuePhase.md): The phase of the project an issue belongs to.
- [`IssuePosition`](https://docs.archipad.dev/apis/archipad-graphql/types/IssuePosition.md): Where an issue is pinned on its plan.
- [`IssueRegion`](https://docs.archipad.dev/apis/archipad-graphql/types/IssueRegion.md): The region of an issue: the lot or zone of the project, such as an apartment, its plan belongs to.
- [`IssueRegionMember`](https://docs.archipad.dev/apis/archipad-graphql/types/IssueRegionMember.md): A person attached to the region of an issue, such as a buyer of the lot.
- [`PageInfo`](https://docs.archipad.dev/apis/archipad-graphql/types/PageInfo.md): Where a page stands in the list it was cut from, as in the GraphQL Cursor Connections Specification.
- [`Phase`](https://docs.archipad.dev/apis/archipad-graphql/types/Phase.md): A phase of a project.
- [`Project`](https://docs.archipad.dev/apis/archipad-graphql/types/Project.md): A construction project in Archipad.
- [`ProjectConnection`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectConnection.md): A page of projects, as in the GraphQL Cursor Connections Specification: `edges` carry the projects and their cursors, `pageInfo` tells whether a page follows and how to ask for it.
- [`ProjectEdge`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectEdge.md): One of the projects of a page, with the cursor that points at it.
- [`ProjectParticipant`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipant.md): A person with access to a project.
- [`ProjectParticipantCompany`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipantCompany.md): The company a participant of a project works for.
- [`ProjectParticipantContact`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipantContact.md): How to reach a participant of a project.
- [`ProjectParticipantPermissions`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipantPermissions.md): The set of permissions a participant has on a project.
- [`ProjectParticipantTrade`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipantTrade.md): A trade a participant holds on a project: a project member role, such as architect, or a work package they are the contact of.
- [`ProjectParticipantTradeCategory`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipantTradeCategory.md): A group of trades: the project member roles, or the work packages.
- [`ProjectParticipantUser`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipantUser.md): The Archipad account of a participant of a project.
- [`ProjectRegion`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectRegion.md): A region of a project: a lot or zone, such as an apartment, that plans and their issues belong to.
- [`ProjectRegionEdge`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectRegionEdge.md): One of the regions of a page, with the cursor that points at it.
- [`RegionConnection`](https://docs.archipad.dev/apis/archipad-graphql/types/RegionConnection.md): A page of regions, as in the GraphQL Cursor Connections Specification: `edges` carry the regions and their cursors, `pageInfo` tells whether a page follows and how to ask for it.
- [`RegionMember`](https://docs.archipad.dev/apis/archipad-graphql/types/RegionMember.md): A person attached to a region of a project, such as a buyer of the lot.
- [`RegionType`](https://docs.archipad.dev/apis/archipad-graphql/types/RegionType.md): The type of a region, such as a building, a floor or an apartment.

## Inputs

- [`IssueRegionMembersFilterInput`](https://docs.archipad.dev/apis/archipad-graphql/types/IssueRegionMembersFilterInput.md): Narrows the members of a region.
- [`ProjectParticipantsFilterInput`](https://docs.archipad.dev/apis/archipad-graphql/types/ProjectParticipantsFilterInput.md): Narrows the participants of a project. A participant must match every filter given; a filter omitted or null narrows nothing, an empty one keeps no participant.
- [`RegionsFilterInput`](https://docs.archipad.dev/apis/archipad-graphql/types/RegionsFilterInput.md): Narrows the regions; the fields given all apply, those omitted or null narrow nothing.

## Scalars

- [`DateTime`](https://docs.archipad.dev/apis/archipad-graphql/types/DateTime.md): A date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.
- [`LocalDate`](https://docs.archipad.dev/apis/archipad-graphql/types/LocalDate.md): A calendar day, without a time of day or a time zone, in the ISO 8601 form `YYYY-MM-DD`, such as `2026-10-15`.
- [`UUID`](https://docs.archipad.dev/apis/archipad-graphql/types/UUID.md): A UUID, in its canonical hyphenated form (`123e4567-e89b-12d3-a456-426614174000`) or as 32 hex digits.
