/* tslint:disable */ /* eslint-disable */ // @ts-nocheck /** * Audius API * * The version of the OpenAPI document: 1.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { exists, mapValues } from '../runtime'; import type { UpdateUserRequestBodyEvents } from './UpdateUserRequestBodyEvents'; import { UpdateUserRequestBodyEventsFromJSON, UpdateUserRequestBodyEventsFromJSONTyped, UpdateUserRequestBodyEventsToJSON, } from './UpdateUserRequestBodyEvents'; import type { UserPlaylistLibrary } from './UserPlaylistLibrary'; import { UserPlaylistLibraryFromJSON, UserPlaylistLibraryFromJSONTyped, UserPlaylistLibraryToJSON, } from './UserPlaylistLibrary'; /** * * @export * @interface CreateUserRequestBody */ export interface CreateUserRequestBody { /** * Optional user hash ID (will be generated if not provided) * @type {string} * @memberof CreateUserRequestBody */ userId?: string; /** * User handle (unique username) * @type {string} * @memberof CreateUserRequestBody */ handle: string; /** * Wallet address (required) * @type {string} * @memberof CreateUserRequestBody */ wallet: string; /** * Display name * @type {string} * @memberof CreateUserRequestBody */ name?: string; /** * User bio * @type {string} * @memberof CreateUserRequestBody */ bio?: string; /** * User location * @type {string} * @memberof CreateUserRequestBody */ location?: string; /** * Website URL * @type {string} * @memberof CreateUserRequestBody */ website?: string; /** * Donation link * @type {string} * @memberof CreateUserRequestBody */ donation?: string; /** * Twitter handle (without @) * @type {string} * @memberof CreateUserRequestBody */ twitterHandle?: string; /** * Instagram handle (without @) * @type {string} * @memberof CreateUserRequestBody */ instagramHandle?: string; /** * TikTok handle (without @) * @type {string} * @memberof CreateUserRequestBody */ tiktokHandle?: string; /** * Profile picture CID or URL * @type {string} * @memberof CreateUserRequestBody */ profilePicture?: string; /** * Profile picture sizes metadata * @type {string} * @memberof CreateUserRequestBody */ profilePictureSizes?: string; /** * Cover photo CID or URL * @type {string} * @memberof CreateUserRequestBody */ coverPhoto?: string; /** * Cover photo sizes metadata * @type {string} * @memberof CreateUserRequestBody */ coverPhotoSizes?: string; /** * Type of profile (e.g., 'label' for record labels) * @type {string} * @memberof CreateUserRequestBody */ profileType?: CreateUserRequestBodyProfileTypeEnum; /** * Whether to allow AI attribution * @type {boolean} * @memberof CreateUserRequestBody */ allowAiAttribution?: boolean; /** * Solana USDC payout wallet address * @type {string} * @memberof CreateUserRequestBody */ splUsdcPayoutWallet?: string; /** * * @type {UserPlaylistLibrary} * @memberof CreateUserRequestBody */ playlistLibrary?: UserPlaylistLibrary; /** * * @type {UpdateUserRequestBodyEvents} * @memberof CreateUserRequestBody */ events?: UpdateUserRequestBodyEvents; } /** * @export */ export const CreateUserRequestBodyProfileTypeEnum = { Label: 'label' } as const; export type CreateUserRequestBodyProfileTypeEnum = typeof CreateUserRequestBodyProfileTypeEnum[keyof typeof CreateUserRequestBodyProfileTypeEnum]; /** * Check if a given object implements the CreateUserRequestBody interface. */ export function instanceOfCreateUserRequestBody(value: object): value is CreateUserRequestBody { let isInstance = true; isInstance = isInstance && "handle" in value && value["handle"] !== undefined; isInstance = isInstance && "wallet" in value && value["wallet"] !== undefined; return isInstance; } export function CreateUserRequestBodyFromJSON(json: any): CreateUserRequestBody { return CreateUserRequestBodyFromJSONTyped(json, false); } export function CreateUserRequestBodyFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateUserRequestBody { if ((json === undefined) || (json === null)) { return json; } return { 'userId': !exists(json, 'user_id') ? undefined : json['user_id'], 'handle': json['handle'], 'wallet': json['wallet'], 'name': !exists(json, 'name') ? undefined : json['name'], 'bio': !exists(json, 'bio') ? undefined : json['bio'], 'location': !exists(json, 'location') ? undefined : json['location'], 'website': !exists(json, 'website') ? undefined : json['website'], 'donation': !exists(json, 'donation') ? undefined : json['donation'], 'twitterHandle': !exists(json, 'twitter_handle') ? undefined : json['twitter_handle'], 'instagramHandle': !exists(json, 'instagram_handle') ? undefined : json['instagram_handle'], 'tiktokHandle': !exists(json, 'tiktok_handle') ? undefined : json['tiktok_handle'], 'profilePicture': !exists(json, 'profile_picture') ? undefined : json['profile_picture'], 'profilePictureSizes': !exists(json, 'profile_picture_sizes') ? undefined : json['profile_picture_sizes'], 'coverPhoto': !exists(json, 'cover_photo') ? undefined : json['cover_photo'], 'coverPhotoSizes': !exists(json, 'cover_photo_sizes') ? undefined : json['cover_photo_sizes'], 'profileType': !exists(json, 'profile_type') ? undefined : json['profile_type'], 'allowAiAttribution': !exists(json, 'allow_ai_attribution') ? undefined : json['allow_ai_attribution'], 'splUsdcPayoutWallet': !exists(json, 'spl_usdc_payout_wallet') ? undefined : json['spl_usdc_payout_wallet'], 'playlistLibrary': !exists(json, 'playlist_library') ? undefined : UserPlaylistLibraryFromJSON(json['playlist_library']), 'events': !exists(json, 'events') ? undefined : UpdateUserRequestBodyEventsFromJSON(json['events']), }; } export function CreateUserRequestBodyToJSON(value?: CreateUserRequestBody | null): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { 'user_id': value.userId, 'handle': value.handle, 'wallet': value.wallet, 'name': value.name, 'bio': value.bio, 'location': value.location, 'website': value.website, 'donation': value.donation, 'twitter_handle': value.twitterHandle, 'instagram_handle': value.instagramHandle, 'tiktok_handle': value.tiktokHandle, 'profile_picture': value.profilePicture, 'profile_picture_sizes': value.profilePictureSizes, 'cover_photo': value.coverPhoto, 'cover_photo_sizes': value.coverPhotoSizes, 'profile_type': value.profileType, 'allow_ai_attribution': value.allowAiAttribution, 'spl_usdc_payout_wallet': value.splUsdcPayoutWallet, 'playlist_library': UserPlaylistLibraryToJSON(value.playlistLibrary), 'events': UpdateUserRequestBodyEventsToJSON(value.events), }; }