Browse Source

👷🏻‍♀️ Update CI for client generation (#1573)

pull/13907/head
Alejandra 3 months ago
committed by GitHub
parent
commit
893f5ff3ce
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 1
      .github/workflows/generate-client.yml
  2. 26
      frontend/src/client/sdk.gen.ts
  3. 13
      frontend/src/client/types.gen.ts

1
.github/workflows/generate-client.yml

@ -39,7 +39,6 @@ jobs:
- run: uv run bash scripts/generate-client.sh
env:
VIRTUAL_ENV: backend/.venv
ENVIRONMENT: production
SECRET_KEY: just-for-generating-client
POSTGRES_PASSWORD: just-for-generating-client
FIRST_SUPERUSER_PASSWORD: just-for-generating-client

26
frontend/src/client/sdk.gen.ts

@ -23,6 +23,8 @@ import type {
LoginResetPasswordResponse,
LoginRecoverPasswordHtmlContentData,
LoginRecoverPasswordHtmlContentResponse,
PrivateCreateUserData,
PrivateCreateUserResponse,
UsersReadUsersData,
UsersReadUsersResponse,
UsersCreateUserData,
@ -272,6 +274,30 @@ export class LoginService {
}
}
export class PrivateService {
/**
* Create User
* Create a new user.
* @param data The data for the request.
* @param data.requestBody
* @returns UserPublic Successful Response
* @throws ApiError
*/
public static createUser(
data: PrivateCreateUserData,
): CancelablePromise<PrivateCreateUserResponse> {
return __request(OpenAPI, {
method: "POST",
url: "/api/v1/private/users/",
body: data.requestBody,
mediaType: "application/json",
errors: {
422: "Validation Error",
},
})
}
}
export class UsersService {
/**
* Read Users

13
frontend/src/client/types.gen.ts

@ -44,6 +44,13 @@ export type NewPassword = {
new_password: string
}
export type PrivateUserCreate = {
email: string
password: string
full_name: string
is_verified?: boolean
}
export type Token = {
access_token: string
token_type?: string
@ -158,6 +165,12 @@ export type LoginRecoverPasswordHtmlContentData = {
export type LoginRecoverPasswordHtmlContentResponse = string
export type PrivateCreateUserData = {
requestBody: PrivateUserCreate
}
export type PrivateCreateUserResponse = UserPublic
export type UsersReadUsersData = {
limit?: number
skip?: number

Loading…
Cancel
Save