diff --git a/api/swagger/swagger-v1.yaml b/api/swagger/swagger-v1.yaml index 0d22ebae..b75e3e0b 100644 --- a/api/swagger/swagger-v1.yaml +++ b/api/swagger/swagger-v1.yaml @@ -3623,6 +3623,45 @@ paths: "500": description: Server error content: {} + put: + tags: + - users + description: Updates an existing user profile + operationId: Update User + security: + - BasicAuth: [] + parameters: + - name: id + in: path + description: A User ID + required: true + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/update_user_request' + responses: + "200": + description: User updated successfully + content: + application/json: + schema: + $ref: '#/components/schemas/write_response' + "400": + description: Bad request + content: {} + "401": + description: Unauthorized + content: {} + "404": + description: User not found + content: {} + "500": + description: Server error + content: {} /users/{id}/albums: get: tags: @@ -9592,6 +9631,11 @@ components: cover_photo_sizes: type: string description: Cover photo sizes metadata + profile_type: + type: string + nullable: true + enum: [label] + description: Type of profile (e.g., 'label' for record labels) allow_ai_attribution: type: boolean description: Whether to allow AI attribution @@ -9640,6 +9684,11 @@ components: cover_photo_sizes: type: string description: Cover photo sizes metadata + profile_type: + type: string + nullable: true + enum: [label] + description: Type of profile (e.g., 'label' for record labels) is_deactivated: type: boolean description: Whether the user is deactivated diff --git a/api/v1_users.go b/api/v1_users.go index cc9345be..59a0afba 100644 --- a/api/v1_users.go +++ b/api/v1_users.go @@ -42,6 +42,7 @@ type CreateUserRequest struct { ProfilePictureSizes *string `json:"profile_picture_sizes,omitempty"` CoverPhoto *string `json:"cover_photo,omitempty"` CoverPhotoSizes *string `json:"cover_photo_sizes,omitempty"` + ProfileType *string `json:"profile_type,omitempty" validate:"omitempty,oneof=label"` AllowAiAttribution *bool `json:"allow_ai_attribution,omitempty"` SplUsdcPayoutWallet *string `json:"spl_usdc_payout_wallet,omitempty"` } @@ -59,6 +60,7 @@ type UpdateUserRequest struct { ProfilePictureSizes *string `json:"profile_picture_sizes,omitempty"` CoverPhoto *string `json:"cover_photo,omitempty"` CoverPhotoSizes *string `json:"cover_photo_sizes,omitempty"` + ProfileType *string `json:"profile_type,omitempty" validate:"omitempty,oneof=label"` IsDeactivated *bool `json:"is_deactivated,omitempty"` ArtistPickTrackId *string `json:"artist_pick_track_id,omitempty"` AllowAiAttribution *bool `json:"allow_ai_attribution,omitempty"`