[go: up one dir, main page]

Skip to content

Discussion: GraphQL and REST API parity

Background

Continuing discussion from !146250 (comment 1802034674). While building Organizations we have generally followed these guidelines:

  1. If a GraphQL API already exists, use that
  2. If a REST API already exists, use that
  3. If we need a new API, build it with GraphQL

Our guidelines suggest that the GraphQL API should be the "primary means of interacting programmatically with GitLab".

We want the GraphQL API to be the primary means of interacting programmatically with GitLab. To achieve this, it needs full coverage - anything possible in the REST API should also be possible in the GraphQL API.

Questions to discuss

Feel free to add questions below

  1. If a REST API already exists, should we implement a GraphQL mutation before building the frontend of the feature? One example is deleting a project. This is already possible via REST API but not GraphQL so we used the REST API to be more efficient.
  2. How can we keep track of REST API vs GraphQL feature parity?
Edited by Peter Hegman