mirror of
https://github.com/LukeHagar/discoursejs.git
synced 2025-12-09 20:37:45 +00:00
ci: regenerated with OpenAPI Doc latest, Speakeasy CLI 1.134.1
This commit is contained in:
130
src/sdk/models/operations/createupload.ts
Normal file
130
src/sdk/models/operations/createupload.ts
Normal file
@@ -0,0 +1,130 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
import { SpeakeasyBase, SpeakeasyMetadata } from "../../../internal/utils";
|
||||
import { AxiosResponse } from "axios";
|
||||
import { Expose } from "class-transformer";
|
||||
|
||||
export class File extends SpeakeasyBase {
|
||||
@SpeakeasyMetadata({ data: "multipart_form, content=true" })
|
||||
content: Uint8Array;
|
||||
|
||||
@SpeakeasyMetadata({ data: "multipart_form, name=file" })
|
||||
fileName: string;
|
||||
}
|
||||
|
||||
export enum TypeT {
|
||||
Avatar = "avatar",
|
||||
ProfileBackground = "profile_background",
|
||||
CardBackground = "card_background",
|
||||
CustomEmoji = "custom_emoji",
|
||||
Composer = "composer",
|
||||
}
|
||||
|
||||
export class CreateUploadRequestBody extends SpeakeasyBase {
|
||||
@SpeakeasyMetadata({ data: "multipart_form, file=true" })
|
||||
file?: File;
|
||||
|
||||
/**
|
||||
* Use this flag to return an id and url
|
||||
*/
|
||||
@SpeakeasyMetadata({ data: "multipart_form, name=synchronous" })
|
||||
synchronous?: boolean;
|
||||
|
||||
@SpeakeasyMetadata({ data: "multipart_form, name=type" })
|
||||
type: TypeT;
|
||||
|
||||
/**
|
||||
* required if uploading an avatar
|
||||
*/
|
||||
@SpeakeasyMetadata({ data: "multipart_form, name=user_id" })
|
||||
userId?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* file uploaded
|
||||
*/
|
||||
export class CreateUploadResponseBody extends SpeakeasyBase {
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "dominant_color" })
|
||||
dominantColor?: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "extension" })
|
||||
extension: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "filesize" })
|
||||
filesize: number;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "height" })
|
||||
height: number;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "human_filesize" })
|
||||
humanFilesize: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "id" })
|
||||
id: number;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "original_filename" })
|
||||
originalFilename: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "retain_hours" })
|
||||
retainHours: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "short_path" })
|
||||
shortPath: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "short_url" })
|
||||
shortUrl: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "thumbnail_height" })
|
||||
thumbnailHeight: number;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "thumbnail_width" })
|
||||
thumbnailWidth: number;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "url" })
|
||||
url: string;
|
||||
|
||||
@SpeakeasyMetadata()
|
||||
@Expose({ name: "width" })
|
||||
width: number;
|
||||
}
|
||||
|
||||
export class CreateUploadResponse extends SpeakeasyBase {
|
||||
/**
|
||||
* HTTP response content type for this operation
|
||||
*/
|
||||
@SpeakeasyMetadata()
|
||||
contentType: string;
|
||||
|
||||
/**
|
||||
* HTTP response status code for this operation
|
||||
*/
|
||||
@SpeakeasyMetadata()
|
||||
statusCode: number;
|
||||
|
||||
/**
|
||||
* Raw HTTP response; suitable for custom response parsing
|
||||
*/
|
||||
@SpeakeasyMetadata()
|
||||
rawResponse: AxiosResponse;
|
||||
|
||||
/**
|
||||
* file uploaded
|
||||
*/
|
||||
@SpeakeasyMetadata()
|
||||
object?: CreateUploadResponseBody;
|
||||
}
|
||||
Reference in New Issue
Block a user