Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update openapi spec with identity and is_anonymous fields (supa…
…base#1573) ## What kind of change does this PR introduce? Adds the `Identity` and `is_anonymous` fields to OpenAPI spec. This is so we can use the `openapi.yml` as a sgeneral reference from which to generate Hook Payloads, which contain `User` objects. Identity Fields taken from the [identity model](https://github.com/supabase/auth/blob/master/internal/api/identity.go) ## More Context User objects are generated by: 1. Converting the `openapi.yml` into JSONSchema. Currently this is done via OpenAI though a modified version of [a yml to jsonschema converter should work with modifications as well](https://www.npmjs.com/package/yaml-to-json-schema). We don't use the latter as there's an additional step of converting the output jsonschema into a format that JSON Faker can accept (adding the JSONSchema version etc) 2. Using [JSONSchema to generate a fake payload](https://json-schema-faker.js.org/) ## Use The plan is to embed the JSONSchema into each Hook example so developers can copy paste into JSONSchema Faker or similar tool to generate a fake payload.
- Loading branch information