Download OpenAPI specification:Download
Flickz is a platform that connects event photographers with clients. It allows photographers to create profiles, upload event galleries, and sell high-resolution images. Users can browse events, purchase media, and book photographers for future gigs. This API powers both the frontend and backend operations of Flickz, including authentication, media management, and payment processing. This specification is intended for developers working on the Flickz platform, including frontend engineers, backend contributors, and third-party integrators.
Endpoints related to user authentication and account management, including signup, login, password resets, session revocation, and email verification.
Create a user by providing email and password.
Send the user email and password
email required | string <email> |
password required | string >= 8 characters |
{- "email": "foo@gmail.com",
- "password": "your_password_here"
}
{- "success": true,
- "message": "successfully created user account",
- "data": {
- "id": "a45ege4r45re-grtghtrgrtg-tgrtggtrg",
- "handle": "warmachinerocks123",
- "name": "null,",
- "photographerProfile": null,
- "avatar": null,
- "bio": null,
- "userType": "USER",
- "createdAt": "string",
- "updatedAt": "string"
}
}
credentials
email required | string <email> |
password required | string |
{- "email": "user@example.com",
- "password": "string"
}
{- "success": true,
- "message": "successfully created user account",
- "accessToken": "string",
- "tokenType": "string",
- "data": {
- "id": "a45ege4r45re-grtghtrgrtg-tgrtggtrg",
- "handle": "warmachinerocks123",
- "name": "null,",
- "photographerProfile": null,
- "avatar": null,
- "bio": null,
- "userType": "USER",
- "createdAt": "string",
- "updatedAt": "string"
}
}
Revoke an active session token. This endpoint is primarily used to log out a user by marking their session token as invalid. Send the current authenticated user's token in the request body to terminate the session. Once revoked, the token will no longer be accepted for authenticated requests.
token required | string The session token to be revoked. |
{- "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
{- "success": true,
- "message": "Token revoked successfully."
}
Sends a password reset code as a query parameter to the user's email, along with a frontend reset link. The code expires after 8 minutes.
email required | string <email> The email address of the user requesting a password reset. |
{- "email": "user@example.com"
}
{- "success": true,
- "message": "Password reset email sent."
}
Reset a user's password by providing a valid reset code.
code required | string The reset code sent via email with a frontend link. Must be submitted within 8 minutes. |
newPassword | string >= 8 characters the new user password |
{- "code": "string",
- "newPassword": "stringst"
}
{- "success": true,
- "message": "Password reset successfully."
}
Sends a email verification code as a query param atteched to the frontend url
email required | string <email> the email your requesting to /auth/verify-email |
{- "email": "user@example.com"
}
{- "success": true,
- "message": "string"
}
Verify a user's email address using the verification code sent via email.
code required | string The email verification code sent to the user. |
{- "code": "string"
}
{- "success": true,
- "message": "Email verified successfully."
}
Retrieve a list of users with pagination and optional filtering.
page | integer Default: 1 The page number for pagination (default is 1). |
limit | integer Default: 20 The number of users to return per page (default is 10, max is 100). |
{- "success": true,
- "message": "Users retrieved successfully.",
- "items": [
- {
- "id": "12345",
- "name": "Jane Doe",
- "bio": "Event photographer based in NYC.",
- "userType": "PHOTOGRAPHER",
- "handle": "janeshoots",
- "photographerProfile": {
- "id": "profile_123",
- "userId": "user_456",
- "locationLabel": "Los Angeles, CA",
- "bio": "Specializing in weddings and portraits.",
- "phoneNumber": "+1-555-123-4567",
- "responseTime": 2.5,
- "availability": "Weekdays after 4PM, weekends anytime",
- "experienceYears": 5,
- "equipments": [
- "Canon R5",
- "85mm f/1.4",
- "Lighting Kit"
], - "createdAt": "2024-05-01T12:34:56Z",
- "updatedAt": "2024-06-01T08:00:00Z"
}
}
], - "pagination": {
- "page": 1,
- "limit": 20,
- "pageSize": 20,
- "totalPages": 5,
- "total": 100
}
}
Get a user by their unique identifier.
userId required | string The unique identifier of the user to retrieve. |
{- "id": "12345",
- "name": "Jane Doe",
- "bio": "Event photographer based in NYC.",
- "userType": "PHOTOGRAPHER",
- "handle": "janeshoots",
- "photographerProfile": {
- "id": "profile_123",
- "userId": "user_456",
- "locationLabel": "Los Angeles, CA",
- "bio": "Specializing in weddings and portraits.",
- "phoneNumber": "+1-555-123-4567",
- "responseTime": 2.5,
- "availability": "Weekdays after 4PM, weekends anytime",
- "experienceYears": 5,
- "equipments": [
- "Canon R5",
- "85mm f/1.4",
- "Lighting Kit"
], - "createdAt": "2024-05-01T12:34:56Z",
- "updatedAt": "2024-06-01T08:00:00Z"
}
}
Retrieve a public user profile by their unique handle.
handle required | string The unique handle (username) of the user to retrieve. |
{- "id": "12345",
- "name": "Jane Doe",
- "bio": "Event photographer based in NYC.",
- "userType": "PHOTOGRAPHER",
- "handle": "janeshoots",
- "photographerProfile": {
- "id": "profile_123",
- "userId": "user_456",
- "locationLabel": "Los Angeles, CA",
- "bio": "Specializing in weddings and portraits.",
- "phoneNumber": "+1-555-123-4567",
- "responseTime": 2.5,
- "availability": "Weekdays after 4PM, weekends anytime",
- "experienceYears": 5,
- "equipments": [
- "Canon R5",
- "85mm f/1.4",
- "Lighting Kit"
], - "createdAt": "2024-05-01T12:34:56Z",
- "updatedAt": "2024-06-01T08:00:00Z"
}
}
Verify whether a user handle (username) is available for registration.
handle required | string The handle (username) to check for availability. |
{- "success": true,
- "message": "Handle is available.",
- "data": {
- "available": true,
- "handle": "janeshoots"
}
}
Retrieve the profile of the currently authenticated user.
{- "success": true,
- "message": "User profile retrieved successfully.",
- "data": {
- "id": "user_123",
- "name": "Jane Doe",
- "email": "jane@example.com",
- "bio": "Portrait and event photographer based in LA.",
- "userType": "PHOTOGRAPHER",
- "handle": "janeshoots",
- "isEmailVerified": true,
- "photographerProfile": {
- "id": "profile_123",
- "userId": "user_456",
- "locationLabel": "Los Angeles, CA",
- "bio": "Specializing in weddings and portraits.",
- "phoneNumber": "+1-555-123-4567",
- "responseTime": 2.5,
- "availability": "Weekdays after 4PM, weekends anytime",
- "experienceYears": 5,
- "equipments": [
- "Canon R5",
- "85mm f/1.4",
- "Lighting Kit"
], - "createdAt": "2024-05-01T12:34:56Z",
- "updatedAt": "2024-06-01T08:00:00Z"
}
}
}
Update the profile of the currently authenticated user.
name | string or null <= 100 characters Optional name of the user (max 100 characters). |
bio | string or null <= 1000 characters Optional biography of the user (max 1000 characters). |
userType | string or null Enum: "USER" "PHOTOGRAPHER" The role or type of user. Must be either USER or PHOTOGRAPHER. |
handle | string or null [ 3 .. 30 ] characters ^[a-zA-Z0-9_]+$ Unique handle (username), 3–30 characters. Only letters, numbers, and underscores are allowed. |
{- "name": "Jane Doe",
- "bio": "Photographer based in LA, specializing in weddings.",
- "userType": "PHOTOGRAPHER",
- "handle": "jane_doe"
}
{- "success": true,
- "message": "User profile updated successfully.",
- "data": {
- "id": "user_123",
- "name": "Jane Doe",
- "email": "jane@example.com",
- "bio": "Portrait and event photographer based in LA.",
- "userType": "PHOTOGRAPHER",
- "handle": "janeshoots",
- "isEmailVerified": true,
- "photographerProfile": {
- "id": "profile_123",
- "userId": "user_456",
- "locationLabel": "Los Angeles, CA",
- "bio": "Specializing in weddings and portraits.",
- "phoneNumber": "+1-555-123-4567",
- "responseTime": 2.5,
- "availability": "Weekdays after 4PM, weekends anytime",
- "experienceYears": 5,
- "equipments": [
- "Canon R5",
- "85mm f/1.4",
- "Lighting Kit"
], - "createdAt": "2024-05-01T12:34:56Z",
- "updatedAt": "2024-06-01T08:00:00Z"
}
}
}
Upload and update the current authenticated user's avatar image.
avatar | string <binary> <= 10485760 characters Avatar image file to upload. Accepts JPEG, PNG, or WebP formats. Max size: 10MB. |
{- "success": true,
- "message": "User avatar updated successfully."
}