repo_name string | dataset string | owner string | lang string | func_name string | code string | docstring string | url string | sha string |
|---|---|---|---|---|---|---|---|---|
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.getCharacterSummaryWithHttpInfo | public async getCharacterSummaryWithHttpInfo(response: ResponseContext): Promise<HttpInfo<CharacterSummaryDTO >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: CharacterSummaryDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"CharacterSummaryDTO", ""
) as CharacterSummaryDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: CharacterSummaryDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"CharacterSummaryDTO", ""
) as CharacterSummaryDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to getCharacterSummary
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2357-L2377 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.getDefaultCharacterBackendWithHttpInfo | public async getDefaultCharacterBackendWithHttpInfo(response: ResponseContext): Promise<HttpInfo<CharacterBackendDetailsDTO >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: CharacterBackendDetailsDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"CharacterBackendDetailsDTO", ""
) as CharacterBackendDetailsDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: CharacterBackendDetailsDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"CharacterBackendDetailsDTO", ""
) as CharacterBackendDetailsDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to getDefaultCharacterBackend
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2386-L2406 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.importCharacterWithHttpInfo | public async importCharacterWithHttpInfo(response: ResponseContext): Promise<HttpInfo<number >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to importCharacter
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2415-L2435 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.listCharacterBackendIdsWithHttpInfo | public async listCharacterBackendIdsWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<string> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharacterBackendIds
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2444-L2464 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.listCharacterBackendsWithHttpInfo | public async listCharacterBackendsWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterBackendDetailsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterBackendDetailsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterBackendDetailsDTO>", ""
) as Array<CharacterBackendDetailsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterBackendDetailsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterBackendDetailsDTO>", ""
) as Array<CharacterBackendDetailsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharacterBackends
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2473-L2493 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.listCharacterDocumentsWithHttpInfo | public async listCharacterDocumentsWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<string> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharacterDocuments
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2502-L2522 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.listCharacterPicturesWithHttpInfo | public async listCharacterPicturesWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<string> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharacterPictures
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2531-L2551 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.listCharacterVersionsByNameWithHttpInfo | public async listCharacterVersionsByNameWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterItemForNameDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterItemForNameDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterItemForNameDTO>", ""
) as Array<CharacterItemForNameDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterItemForNameDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterItemForNameDTO>", ""
) as Array<CharacterItemForNameDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharacterVersionsByName
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2560-L2580 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.listCharacterVoicesWithHttpInfo | public async listCharacterVoicesWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<string> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<string> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<string>", ""
) as Array<string>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharacterVoices
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2589-L2609 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.newCharacterNameWithHttpInfo | public async newCharacterNameWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to newCharacterName
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2618-L2638 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.publishCharacterWithHttpInfo | public async publishCharacterWithHttpInfo(response: ResponseContext): Promise<HttpInfo<number >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to publishCharacter
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2647-L2667 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.publishCharacter1WithHttpInfo | public async publishCharacter1WithHttpInfo(response: ResponseContext): Promise<HttpInfo<number >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to publishCharacter1
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2676-L2696 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.removeCharacterBackendWithHttpInfo | public async removeCharacterBackendWithHttpInfo(response: ResponseContext): Promise<HttpInfo<boolean >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to removeCharacterBackend
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2705-L2725 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.searchCharacterDetailsWithHttpInfo | public async searchCharacterDetailsWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterDetailsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterDetailsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterDetailsDTO>", ""
) as Array<CharacterDetailsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterDetailsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterDetailsDTO>", ""
) as Array<CharacterDetailsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to searchCharacterDetails
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2734-L2754 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.searchCharacterSummaryWithHttpInfo | public async searchCharacterSummaryWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterSummaryDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterSummaryDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryDTO>", ""
) as Array<CharacterSummaryDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterSummaryDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryDTO>", ""
) as Array<CharacterSummaryDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to searchCharacterSummary
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2763-L2783 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.searchPublicCharacterSummaryWithHttpInfo | public async searchPublicCharacterSummaryWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterSummaryDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterSummaryDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryDTO>", ""
) as Array<CharacterSummaryDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterSummaryDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryDTO>", ""
) as Array<CharacterSummaryDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to searchPublicCharacterSummary
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2792-L2812 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.setDefaultCharacterBackendWithHttpInfo | public async setDefaultCharacterBackendWithHttpInfo(response: ResponseContext): Promise<HttpInfo<boolean >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to setDefaultCharacterBackend
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2821-L2841 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.updateCharacterWithHttpInfo | public async updateCharacterWithHttpInfo(response: ResponseContext): Promise<HttpInfo<boolean >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to updateCharacter
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2850-L2870 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.updateCharacterBackendWithHttpInfo | public async updateCharacterBackendWithHttpInfo(response: ResponseContext): Promise<HttpInfo<boolean >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to updateCharacterBackend
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2879-L2899 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.uploadCharacterAvatarWithHttpInfo | public async uploadCharacterAvatarWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to uploadCharacterAvatar
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2908-L2928 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.uploadCharacterDocumentWithHttpInfo | public async uploadCharacterDocumentWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to uploadCharacterDocument
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2937-L2957 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.uploadCharacterPictureWithHttpInfo | public async uploadCharacterPictureWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to uploadCharacterPicture
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2966-L2986 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | CharacterApiResponseProcessor.uploadCharacterVoiceWithHttpInfo | public async uploadCharacterVoiceWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to uploadCharacterVoice
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/CharacterApi.ts#L2995-L3015 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.clearMemory | public async clearMemory(chatId: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "clearMemory", "chatId");
}
// Path Params
const localVarPath = '/api/v2/chat/memory/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.DELETE);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Clear memory of the chat session.
* Clear Memory
* @param chatId Chat session identifier
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L30-L61 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.deleteChat | public async deleteChat(chatId: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "deleteChat", "chatId");
}
// Path Params
const localVarPath = '/api/v2/chat/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.DELETE);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Delete the chat session.
* Delete Chat Session
* @param chatId Chat session identifier
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L68-L99 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.getDefaultChatId | public async getDefaultChatId(characterUid: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'characterUid' is not null or undefined
if (characterUid === null || characterUid === undefined) {
throw new RequiredError("ChatApi", "getDefaultChatId", "characterUid");
}
// Path Params
const localVarPath = '/api/v2/chat/{characterUid}'
.replace('{' + 'characterUid' + '}', encodeURIComponent(String(characterUid)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get default chat id of current user and the character.
* Get Default Chat
* @param characterUid Character uid
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L106-L137 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.getMemoryUsage | public async getMemoryUsage(chatId: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "getMemoryUsage", "chatId");
}
// Path Params
const localVarPath = '/api/v2/chat/memory/usage/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get memory usage of a chat.
* Get Memory Usage
* @param chatId Chat session identifier
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L144-L175 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.listChats | public async listChats(_options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// Path Params
const localVarPath = '/api/v2/chat';
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List chats of current user.
* List Chats
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L181-L205 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.listDebugMessages | public async listDebugMessages(chatId: string, limit: number, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "listDebugMessages", "chatId");
}
// verify required parameter 'limit' is not null or undefined
if (limit === null || limit === undefined) {
throw new RequiredError("ChatApi", "listDebugMessages", "limit");
}
// Path Params
const localVarPath = '/api/v2/chat/messages/debug/{chatId}/{limit}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)))
.replace('{' + 'limit' + '}', encodeURIComponent(String(limit)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List debug messages of a chat.
* List Chat Debug Messages
* @param chatId Chat session identifier
* @param limit Messages limit
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L213-L251 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.listDebugMessages1 | public async listDebugMessages1(chatId: string, limit: number, offset: number, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "listDebugMessages1", "chatId");
}
// verify required parameter 'limit' is not null or undefined
if (limit === null || limit === undefined) {
throw new RequiredError("ChatApi", "listDebugMessages1", "limit");
}
// verify required parameter 'offset' is not null or undefined
if (offset === null || offset === undefined) {
throw new RequiredError("ChatApi", "listDebugMessages1", "offset");
}
// Path Params
const localVarPath = '/api/v2/chat/messages/debug/{chatId}/{limit}/{offset}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)))
.replace('{' + 'limit' + '}', encodeURIComponent(String(limit)))
.replace('{' + 'offset' + '}', encodeURIComponent(String(offset)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List debug messages of a chat.
* List Chat Debug Messages
* @param chatId Chat session identifier
* @param limit Messages limit
* @param offset Messages offset (from new to old)
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L260-L305 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.listDebugMessages2 | public async listDebugMessages2(chatId: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "listDebugMessages2", "chatId");
}
// Path Params
const localVarPath = '/api/v2/chat/messages/debug/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List debug messages of a chat.
* List Chat Debug Messages
* @param chatId Chat session identifier
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L312-L343 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.listMessages | public async listMessages(chatId: string, limit: number, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "listMessages", "chatId");
}
// verify required parameter 'limit' is not null or undefined
if (limit === null || limit === undefined) {
throw new RequiredError("ChatApi", "listMessages", "limit");
}
// Path Params
const localVarPath = '/api/v2/chat/messages/{chatId}/{limit}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)))
.replace('{' + 'limit' + '}', encodeURIComponent(String(limit)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List messages of a chat.
* List Chat Messages
* @param chatId Chat session identifier
* @param limit Messages limit
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L351-L389 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.listMessages1 | public async listMessages1(chatId: string, limit: number, offset: number, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "listMessages1", "chatId");
}
// verify required parameter 'limit' is not null or undefined
if (limit === null || limit === undefined) {
throw new RequiredError("ChatApi", "listMessages1", "limit");
}
// verify required parameter 'offset' is not null or undefined
if (offset === null || offset === undefined) {
throw new RequiredError("ChatApi", "listMessages1", "offset");
}
// Path Params
const localVarPath = '/api/v2/chat/messages/{chatId}/{limit}/{offset}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)))
.replace('{' + 'limit' + '}', encodeURIComponent(String(limit)))
.replace('{' + 'offset' + '}', encodeURIComponent(String(offset)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List messages of a chat.
* List Chat Messages
* @param chatId Chat session identifier
* @param limit Messages limit
* @param offset Messages offset (from new to old)
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L398-L443 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.listMessages2 | public async listMessages2(chatId: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "listMessages2", "chatId");
}
// Path Params
const localVarPath = '/api/v2/chat/messages/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List messages of a chat.
* List Chat Messages
* @param chatId Chat session identifier
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L450-L481 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.rollbackMessages | public async rollbackMessages(chatId: string, count: number, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "rollbackMessages", "chatId");
}
// verify required parameter 'count' is not null or undefined
if (count === null || count === undefined) {
throw new RequiredError("ChatApi", "rollbackMessages", "count");
}
// Path Params
const localVarPath = '/api/v2/chat/messages/rollback/{chatId}/{count}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)))
.replace('{' + 'count' + '}', encodeURIComponent(String(count)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.POST);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Rollback messages of a chat.
* Rollback Chat Messages
* @param chatId Chat session identifier
* @param count Message count to be rolled back
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L489-L527 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.sendAssistant | public async sendAssistant(chatId: string, assistantUid: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "sendAssistant", "chatId");
}
// verify required parameter 'assistantUid' is not null or undefined
if (assistantUid === null || assistantUid === undefined) {
throw new RequiredError("ChatApi", "sendAssistant", "assistantUid");
}
// Path Params
const localVarPath = '/api/v2/chat/send/assistant/{chatId}/{assistantUid}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)))
.replace('{' + 'assistantUid' + '}', encodeURIComponent(String(assistantUid)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Send a message to assistant for a new chat message.
* Send Assistant for Chat Message
* @param chatId Chat session identifier
* @param assistantUid Assistant uid
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L535-L573 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.sendMessage | public async sendMessage(chatId: string, chatMessageDTO: ChatMessageDTO, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "sendMessage", "chatId");
}
// verify required parameter 'chatMessageDTO' is not null or undefined
if (chatMessageDTO === null || chatMessageDTO === undefined) {
throw new RequiredError("ChatApi", "sendMessage", "chatMessageDTO");
}
// Path Params
const localVarPath = '/api/v2/chat/send/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.POST);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Body Params
const contentType = ObjectSerializer.getPreferredMediaType([
"application/json"
]);
requestContext.setHeaderParam("Content-Type", contentType);
const serializedBody = ObjectSerializer.stringify(
ObjectSerializer.serialize(chatMessageDTO, "ChatMessageDTO", ""),
contentType
);
requestContext.setBody(serializedBody);
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Send a chat message to character.
* Send Chat Message
* @param chatId Chat session identifier
* @param chatMessageDTO Chat message
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L581-L629 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.startChat | public async startChat(chatCreateDTO: ChatCreateDTO, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatCreateDTO' is not null or undefined
if (chatCreateDTO === null || chatCreateDTO === undefined) {
throw new RequiredError("ChatApi", "startChat", "chatCreateDTO");
}
// Path Params
const localVarPath = '/api/v2/chat';
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.POST);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Body Params
const contentType = ObjectSerializer.getPreferredMediaType([
"application/json"
]);
requestContext.setHeaderParam("Content-Type", contentType);
const serializedBody = ObjectSerializer.stringify(
ObjectSerializer.serialize(chatCreateDTO, "ChatCreateDTO", ""),
contentType
);
requestContext.setBody(serializedBody);
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Start a chat session.
* Start Chat Session
* @param chatCreateDTO Parameters for starting a chat session
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L636-L677 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.streamSendAssistant | public async streamSendAssistant(chatId: string, assistantUid: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "streamSendAssistant", "chatId");
}
// verify required parameter 'assistantUid' is not null or undefined
if (assistantUid === null || assistantUid === undefined) {
throw new RequiredError("ChatApi", "streamSendAssistant", "assistantUid");
}
// Path Params
const localVarPath = '/api/v2/chat/send/stream/assistant/{chatId}/{assistantUid}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)))
.replace('{' + 'assistantUid' + '}', encodeURIComponent(String(assistantUid)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Refer to /api/v2/chat/send/assistant/{chatId}/{assistantUid}, stream back chunks of the response.
* Send Assistant for Chat Message by Streaming Back
* @param chatId Chat session identifier
* @param assistantUid Assistant uid
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L685-L723 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.streamSendMessage | public async streamSendMessage(chatId: string, chatMessageDTO: ChatMessageDTO, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "streamSendMessage", "chatId");
}
// verify required parameter 'chatMessageDTO' is not null or undefined
if (chatMessageDTO === null || chatMessageDTO === undefined) {
throw new RequiredError("ChatApi", "streamSendMessage", "chatMessageDTO");
}
// Path Params
const localVarPath = '/api/v2/chat/send/stream/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.POST);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Body Params
const contentType = ObjectSerializer.getPreferredMediaType([
"application/json"
]);
requestContext.setHeaderParam("Content-Type", contentType);
const serializedBody = ObjectSerializer.stringify(
ObjectSerializer.serialize(chatMessageDTO, "ChatMessageDTO", ""),
contentType
);
requestContext.setBody(serializedBody);
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Refer to /api/v2/chat/send/{chatId}, stream back chunks of the response.
* Send Chat Message by Streaming Back
* @param chatId Chat session identifier
* @param chatMessageDTO Chat message
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L731-L779 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiRequestFactory.updateChat | public async updateChat(chatId: string, chatUpdateDTO: ChatUpdateDTO, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'chatId' is not null or undefined
if (chatId === null || chatId === undefined) {
throw new RequiredError("ChatApi", "updateChat", "chatId");
}
// verify required parameter 'chatUpdateDTO' is not null or undefined
if (chatUpdateDTO === null || chatUpdateDTO === undefined) {
throw new RequiredError("ChatApi", "updateChat", "chatUpdateDTO");
}
// Path Params
const localVarPath = '/api/v2/chat/{chatId}'
.replace('{' + 'chatId' + '}', encodeURIComponent(String(chatId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.PUT);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Body Params
const contentType = ObjectSerializer.getPreferredMediaType([
"application/json"
]);
requestContext.setHeaderParam("Content-Type", contentType);
const serializedBody = ObjectSerializer.stringify(
ObjectSerializer.serialize(chatUpdateDTO, "ChatUpdateDTO", ""),
contentType
);
requestContext.setBody(serializedBody);
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Update the chat session.
* Update Chat Session
* @param chatId Chat session identifier
* @param chatUpdateDTO The chat session information to be updated
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L787-L835 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.clearMemoryWithHttpInfo | public async clearMemoryWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatMessageRecordDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to clearMemory
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L848-L868 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.deleteChatWithHttpInfo | public async deleteChatWithHttpInfo(response: ResponseContext): Promise<HttpInfo<boolean >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to deleteChat
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L877-L897 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.getDefaultChatIdWithHttpInfo | public async getDefaultChatIdWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to getDefaultChatId
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L906-L926 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.getMemoryUsageWithHttpInfo | public async getMemoryUsageWithHttpInfo(response: ResponseContext): Promise<HttpInfo<MemoryUsageDTO >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: MemoryUsageDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"MemoryUsageDTO", ""
) as MemoryUsageDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: MemoryUsageDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"MemoryUsageDTO", ""
) as MemoryUsageDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to getMemoryUsage
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L935-L955 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.listChatsWithHttpInfo | public async listChatsWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatSessionDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatSessionDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatSessionDTO>", ""
) as Array<ChatSessionDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatSessionDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatSessionDTO>", ""
) as Array<ChatSessionDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listChats
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L964-L984 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.listDebugMessagesWithHttpInfo | public async listDebugMessagesWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatMessageRecordDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listDebugMessages
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L993-L1013 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.listDebugMessages1WithHttpInfo | public async listDebugMessages1WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatMessageRecordDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listDebugMessages1
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1022-L1042 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.listDebugMessages2WithHttpInfo | public async listDebugMessages2WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatMessageRecordDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listDebugMessages2
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1051-L1071 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.listMessagesWithHttpInfo | public async listMessagesWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatMessageRecordDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listMessages
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1080-L1100 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.listMessages1WithHttpInfo | public async listMessages1WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatMessageRecordDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listMessages1
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1109-L1129 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.listMessages2WithHttpInfo | public async listMessages2WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<ChatMessageRecordDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<ChatMessageRecordDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<ChatMessageRecordDTO>", ""
) as Array<ChatMessageRecordDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listMessages2
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1138-L1158 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.rollbackMessagesWithHttpInfo | public async rollbackMessagesWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<number> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<number> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<number>", "int64"
) as Array<number>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<number> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<number>", "int64"
) as Array<number>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to rollbackMessages
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1167-L1187 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.sendAssistantWithHttpInfo | public async sendAssistantWithHttpInfo(response: ResponseContext): Promise<HttpInfo<LlmResultDTO >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: LlmResultDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"LlmResultDTO", ""
) as LlmResultDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: LlmResultDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"LlmResultDTO", ""
) as LlmResultDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to sendAssistant
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1196-L1216 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.sendMessageWithHttpInfo | public async sendMessageWithHttpInfo(response: ResponseContext): Promise<HttpInfo<LlmResultDTO >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: LlmResultDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"LlmResultDTO", ""
) as LlmResultDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: LlmResultDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"LlmResultDTO", ""
) as LlmResultDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to sendMessage
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1225-L1245 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.startChatWithHttpInfo | public async startChatWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to startChat
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1254-L1274 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.streamSendAssistantWithHttpInfo | public async streamSendAssistantWithHttpInfo(response: ResponseContext): Promise<HttpInfo<SseEmitter >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: SseEmitter = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"SseEmitter", ""
) as SseEmitter;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: SseEmitter = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"SseEmitter", ""
) as SseEmitter;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to streamSendAssistant
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1283-L1303 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.streamSendMessageWithHttpInfo | public async streamSendMessageWithHttpInfo(response: ResponseContext): Promise<HttpInfo<SseEmitter >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: SseEmitter = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"SseEmitter", ""
) as SseEmitter;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: SseEmitter = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"SseEmitter", ""
) as SseEmitter;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to streamSendMessage
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1312-L1332 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | ChatApiResponseProcessor.updateChatWithHttpInfo | public async updateChatWithHttpInfo(response: ResponseContext): Promise<HttpInfo<boolean >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: boolean = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"boolean", ""
) as boolean;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to updateChat
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/ChatApi.ts#L1341-L1361 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | EncryptionManagerForAdminApiRequestFactory.encryptText | public async encryptText(text: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'text' is not null or undefined
if (text === null || text === undefined) {
throw new RequiredError("EncryptionManagerForAdminApi", "encryptText", "text");
}
// Path Params
const localVarPath = '/api/v2/admin/encryption/encrypt/{text}'
.replace('{' + 'text' + '}', encodeURIComponent(String(text)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Encrypt a piece of text with the built-in key.
* Encrypt Text
* @param text Text to be encrypted
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/EncryptionManagerForAdminApi.ts#L22-L53 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | EncryptionManagerForAdminApiResponseProcessor.encryptTextWithHttpInfo | public async encryptTextWithHttpInfo(response: ResponseContext): Promise<HttpInfo<string >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: string = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"string", ""
) as string;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to encryptText
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/EncryptionManagerForAdminApi.ts#L66-L86 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.addStatistic | public async addStatistic(infoType: string, infoId: string, statsType: string, delta: number, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'infoType' is not null or undefined
if (infoType === null || infoType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "addStatistic", "infoType");
}
// verify required parameter 'infoId' is not null or undefined
if (infoId === null || infoId === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "addStatistic", "infoId");
}
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "addStatistic", "statsType");
}
// verify required parameter 'delta' is not null or undefined
if (delta === null || delta === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "addStatistic", "delta");
}
// Path Params
const localVarPath = '/api/v2/stats/{infoType}/{infoId}/{statsType}/{delta}'
.replace('{' + 'infoType' + '}', encodeURIComponent(String(infoType)))
.replace('{' + 'infoId' + '}', encodeURIComponent(String(infoId)))
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'delta' + '}', encodeURIComponent(String(delta)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.POST);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Add the statistics of the corresponding metrics of the corresponding resources. The increment can be negative. Return the latest statistics.
* Add Statistics
* @param infoType Info type: prompt | agent | plugin | character
* @param infoId Unique resource identifier
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param delta Delta in statistical value
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L31-L83 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.getScore | public async getScore(infoType: string, infoId: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'infoType' is not null or undefined
if (infoType === null || infoType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "getScore", "infoType");
}
// verify required parameter 'infoId' is not null or undefined
if (infoId === null || infoId === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "getScore", "infoId");
}
// Path Params
const localVarPath = '/api/v2/public/score/{infoType}/{infoId}'
.replace('{' + 'infoType' + '}', encodeURIComponent(String(infoType)))
.replace('{' + 'infoId' + '}', encodeURIComponent(String(infoId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get the current user\'s score for the corresponding resource.
* Get Score for Resource
* @param infoType Info type: prompt | agent | plugin | character
* @param infoId Unique resource identifier
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L91-L129 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.getStatistic | public async getStatistic(infoType: string, infoId: string, statsType: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'infoType' is not null or undefined
if (infoType === null || infoType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "getStatistic", "infoType");
}
// verify required parameter 'infoId' is not null or undefined
if (infoId === null || infoId === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "getStatistic", "infoId");
}
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "getStatistic", "statsType");
}
// Path Params
const localVarPath = '/api/v2/public/stats/{infoType}/{infoId}/{statsType}'
.replace('{' + 'infoType' + '}', encodeURIComponent(String(infoType)))
.replace('{' + 'infoId' + '}', encodeURIComponent(String(infoId)))
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get the statistics of the corresponding metrics of the corresponding resources.
* Get Statistics
* @param infoType Info type: prompt | agent | plugin | character
* @param infoId Unique resource identifier
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L138-L183 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.getStatistics | public async getStatistics(infoType: string, infoId: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'infoType' is not null or undefined
if (infoType === null || infoType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "getStatistics", "infoType");
}
// verify required parameter 'infoId' is not null or undefined
if (infoId === null || infoId === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "getStatistics", "infoId");
}
// Path Params
const localVarPath = '/api/v2/public/stats/{infoType}/{infoId}'
.replace('{' + 'infoType' + '}', encodeURIComponent(String(infoType)))
.replace('{' + 'infoId' + '}', encodeURIComponent(String(infoId)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get all statistics of the corresponding resources.
* Get All Statistics
* @param infoType Info type: prompt | agent | plugin | character
* @param infoId Unique resource identifier
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L191-L229 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.increaseStatistic | public async increaseStatistic(infoType: string, infoId: string, statsType: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'infoType' is not null or undefined
if (infoType === null || infoType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "increaseStatistic", "infoType");
}
// verify required parameter 'infoId' is not null or undefined
if (infoId === null || infoId === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "increaseStatistic", "infoId");
}
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "increaseStatistic", "statsType");
}
// Path Params
const localVarPath = '/api/v2/stats/{infoType}/{infoId}/{statsType}'
.replace('{' + 'infoType' + '}', encodeURIComponent(String(infoType)))
.replace('{' + 'infoId' + '}', encodeURIComponent(String(infoId)))
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.POST);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Increase the statistics of the corresponding metrics of the corresponding resources by one. Return the latest statistics.
* Increase Statistics
* @param infoType Info type: prompt | agent | plugin | character
* @param infoId Unique resource identifier
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L238-L283 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listAgentsByStatistic | public async listAgentsByStatistic(statsType: string, pageSize: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listAgentsByStatistic", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listAgentsByStatistic", "pageSize");
}
// Path Params
const localVarPath = '/api/v2/public/stats/agents/by/{statsType}/{pageSize}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List agents based on statistics, including interactive statistical data.
* List Agents by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L292-L336 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listAgentsByStatistic1 | public async listAgentsByStatistic1(statsType: string, pageSize: number, pageNum: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listAgentsByStatistic1", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listAgentsByStatistic1", "pageSize");
}
// verify required parameter 'pageNum' is not null or undefined
if (pageNum === null || pageNum === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listAgentsByStatistic1", "pageNum");
}
// Path Params
const localVarPath = '/api/v2/public/stats/agents/by/{statsType}/{pageSize}/{pageNum}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)))
.replace('{' + 'pageNum' + '}', encodeURIComponent(String(pageNum)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List agents based on statistics, including interactive statistical data.
* List Agents by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param pageNum Current page number
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L346-L397 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listAgentsByStatistic2 | public async listAgentsByStatistic2(statsType: string, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listAgentsByStatistic2", "statsType");
}
// Path Params
const localVarPath = '/api/v2/public/stats/agents/by/{statsType}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List agents based on statistics, including interactive statistical data.
* List Agents by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L405-L442 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listCharactersByStatistic | public async listCharactersByStatistic(statsType: string, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listCharactersByStatistic", "statsType");
}
// Path Params
const localVarPath = '/api/v2/public/stats/characters/by/{statsType}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List characters based on statistics, including interactive statistical data.
* List Characters by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L450-L487 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listCharactersByStatistic1 | public async listCharactersByStatistic1(statsType: string, pageSize: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listCharactersByStatistic1", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listCharactersByStatistic1", "pageSize");
}
// Path Params
const localVarPath = '/api/v2/public/stats/characters/by/{statsType}/{pageSize}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List characters based on statistics, including interactive statistical data.
* List Characters by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L496-L540 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listCharactersByStatistic2 | public async listCharactersByStatistic2(statsType: string, pageSize: number, pageNum: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listCharactersByStatistic2", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listCharactersByStatistic2", "pageSize");
}
// verify required parameter 'pageNum' is not null or undefined
if (pageNum === null || pageNum === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listCharactersByStatistic2", "pageNum");
}
// Path Params
const localVarPath = '/api/v2/public/stats/characters/by/{statsType}/{pageSize}/{pageNum}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)))
.replace('{' + 'pageNum' + '}', encodeURIComponent(String(pageNum)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List characters based on statistics, including interactive statistical data.
* List Characters by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param pageNum Current page number
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L550-L601 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listHotTags | public async listHotTags(infoType: string, pageSize: number, text?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'infoType' is not null or undefined
if (infoType === null || infoType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listHotTags", "infoType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listHotTags", "pageSize");
}
// Path Params
const localVarPath = '/api/v2/public/tags/hot/{infoType}/{pageSize}'
.replace('{' + 'infoType' + '}', encodeURIComponent(String(infoType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (text !== undefined) {
requestContext.setQueryParam("text", ObjectSerializer.serialize(text, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get popular tags for a specified info type.
* Hot Tags
* @param infoType Info type: prompt | agent | plugin | character
* @param pageSize Maximum quantity
* @param text Key word
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L610-L654 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listPluginsByStatistic | public async listPluginsByStatistic(statsType: string, pageSize: number, pageNum: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPluginsByStatistic", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPluginsByStatistic", "pageSize");
}
// verify required parameter 'pageNum' is not null or undefined
if (pageNum === null || pageNum === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPluginsByStatistic", "pageNum");
}
// Path Params
const localVarPath = '/api/v2/public/stats/plugins/by/{statsType}/{pageSize}/{pageNum}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)))
.replace('{' + 'pageNum' + '}', encodeURIComponent(String(pageNum)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List plugins based on statistics, including interactive statistical data.
* List Plugins by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param pageNum Current page number
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L664-L715 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listPluginsByStatistic1 | public async listPluginsByStatistic1(statsType: string, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPluginsByStatistic1", "statsType");
}
// Path Params
const localVarPath = '/api/v2/public/stats/plugins/by/{statsType}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List plugins based on statistics, including interactive statistical data.
* List Plugins by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L723-L760 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listPluginsByStatistic2 | public async listPluginsByStatistic2(statsType: string, pageSize: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPluginsByStatistic2", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPluginsByStatistic2", "pageSize");
}
// Path Params
const localVarPath = '/api/v2/public/stats/plugins/by/{statsType}/{pageSize}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List plugins based on statistics, including interactive statistical data.
* List Plugins by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L769-L813 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listPromptsByStatistic | public async listPromptsByStatistic(statsType: string, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPromptsByStatistic", "statsType");
}
// Path Params
const localVarPath = '/api/v2/public/stats/prompts/by/{statsType}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List prompts based on statistics, including interactive statistical data.
* List Prompts by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L821-L858 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listPromptsByStatistic1 | public async listPromptsByStatistic1(statsType: string, pageSize: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPromptsByStatistic1", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPromptsByStatistic1", "pageSize");
}
// Path Params
const localVarPath = '/api/v2/public/stats/prompts/by/{statsType}/{pageSize}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List prompts based on statistics, including interactive statistical data.
* List Prompts by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L867-L911 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiRequestFactory.listPromptsByStatistic2 | public async listPromptsByStatistic2(statsType: string, pageSize: number, pageNum: number, asc?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'statsType' is not null or undefined
if (statsType === null || statsType === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPromptsByStatistic2", "statsType");
}
// verify required parameter 'pageSize' is not null or undefined
if (pageSize === null || pageSize === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPromptsByStatistic2", "pageSize");
}
// verify required parameter 'pageNum' is not null or undefined
if (pageNum === null || pageNum === undefined) {
throw new RequiredError("InteractiveStatisticsApi", "listPromptsByStatistic2", "pageNum");
}
// Path Params
const localVarPath = '/api/v2/public/stats/prompts/by/{statsType}/{pageSize}/{pageNum}'
.replace('{' + 'statsType' + '}', encodeURIComponent(String(statsType)))
.replace('{' + 'pageSize' + '}', encodeURIComponent(String(pageSize)))
.replace('{' + 'pageNum' + '}', encodeURIComponent(String(pageNum)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (asc !== undefined) {
requestContext.setQueryParam("asc", ObjectSerializer.serialize(asc, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* List prompts based on statistics, including interactive statistical data.
* List Prompts by Statistics
* @param statsType Statistics type: view_count | refer_count | recommend_count | score
* @param pageSize Maximum quantity
* @param pageNum Current page number
* @param asc Default is descending order, set asc=1 for ascending order
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L921-L972 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.addStatisticWithHttpInfo | public async addStatisticWithHttpInfo(response: ResponseContext): Promise<HttpInfo<number >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to addStatistic
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L985-L1005 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.getScoreWithHttpInfo | public async getScoreWithHttpInfo(response: ResponseContext): Promise<HttpInfo<number >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to getScore
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1014-L1034 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.getStatisticWithHttpInfo | public async getStatisticWithHttpInfo(response: ResponseContext): Promise<HttpInfo<number >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to getStatistic
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1043-L1063 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.getStatisticsWithHttpInfo | public async getStatisticsWithHttpInfo(response: ResponseContext): Promise<HttpInfo<InteractiveStatsDTO >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: InteractiveStatsDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"InteractiveStatsDTO", ""
) as InteractiveStatsDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: InteractiveStatsDTO = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"InteractiveStatsDTO", ""
) as InteractiveStatsDTO;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to getStatistics
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1072-L1092 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.increaseStatisticWithHttpInfo | public async increaseStatisticWithHttpInfo(response: ResponseContext): Promise<HttpInfo<number >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: number = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"number", "int64"
) as number;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to increaseStatistic
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1101-L1121 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listAgentsByStatisticWithHttpInfo | public async listAgentsByStatisticWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<AgentSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<AgentSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<AgentSummaryStatsDTO>", ""
) as Array<AgentSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<AgentSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<AgentSummaryStatsDTO>", ""
) as Array<AgentSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listAgentsByStatistic
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1130-L1150 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listAgentsByStatistic1WithHttpInfo | public async listAgentsByStatistic1WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<AgentSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<AgentSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<AgentSummaryStatsDTO>", ""
) as Array<AgentSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<AgentSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<AgentSummaryStatsDTO>", ""
) as Array<AgentSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listAgentsByStatistic1
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1159-L1179 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listAgentsByStatistic2WithHttpInfo | public async listAgentsByStatistic2WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<AgentSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<AgentSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<AgentSummaryStatsDTO>", ""
) as Array<AgentSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<AgentSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<AgentSummaryStatsDTO>", ""
) as Array<AgentSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listAgentsByStatistic2
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1188-L1208 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listCharactersByStatisticWithHttpInfo | public async listCharactersByStatisticWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryStatsDTO>", ""
) as Array<CharacterSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryStatsDTO>", ""
) as Array<CharacterSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharactersByStatistic
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1217-L1237 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listCharactersByStatistic1WithHttpInfo | public async listCharactersByStatistic1WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryStatsDTO>", ""
) as Array<CharacterSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryStatsDTO>", ""
) as Array<CharacterSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharactersByStatistic1
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1246-L1266 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listCharactersByStatistic2WithHttpInfo | public async listCharactersByStatistic2WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<CharacterSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<CharacterSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryStatsDTO>", ""
) as Array<CharacterSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<CharacterSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<CharacterSummaryStatsDTO>", ""
) as Array<CharacterSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listCharactersByStatistic2
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1275-L1295 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listHotTagsWithHttpInfo | public async listHotTagsWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<HotTagDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<HotTagDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<HotTagDTO>", ""
) as Array<HotTagDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<HotTagDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<HotTagDTO>", ""
) as Array<HotTagDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listHotTags
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1304-L1324 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listPluginsByStatisticWithHttpInfo | public async listPluginsByStatisticWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<PluginSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<PluginSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PluginSummaryStatsDTO>", ""
) as Array<PluginSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<PluginSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PluginSummaryStatsDTO>", ""
) as Array<PluginSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listPluginsByStatistic
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1333-L1353 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listPluginsByStatistic1WithHttpInfo | public async listPluginsByStatistic1WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<PluginSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<PluginSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PluginSummaryStatsDTO>", ""
) as Array<PluginSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<PluginSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PluginSummaryStatsDTO>", ""
) as Array<PluginSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listPluginsByStatistic1
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1362-L1382 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listPluginsByStatistic2WithHttpInfo | public async listPluginsByStatistic2WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<PluginSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<PluginSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PluginSummaryStatsDTO>", ""
) as Array<PluginSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<PluginSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PluginSummaryStatsDTO>", ""
) as Array<PluginSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listPluginsByStatistic2
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1391-L1411 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listPromptsByStatisticWithHttpInfo | public async listPromptsByStatisticWithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<PromptSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<PromptSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PromptSummaryStatsDTO>", ""
) as Array<PromptSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<PromptSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PromptSummaryStatsDTO>", ""
) as Array<PromptSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listPromptsByStatistic
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1420-L1440 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listPromptsByStatistic1WithHttpInfo | public async listPromptsByStatistic1WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<PromptSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<PromptSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PromptSummaryStatsDTO>", ""
) as Array<PromptSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<PromptSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PromptSummaryStatsDTO>", ""
) as Array<PromptSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listPromptsByStatistic1
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1449-L1469 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | InteractiveStatisticsApiResponseProcessor.listPromptsByStatistic2WithHttpInfo | public async listPromptsByStatistic2WithHttpInfo(response: ResponseContext): Promise<HttpInfo<Array<PromptSummaryStatsDTO> >> {
const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
if (isCodeInRange("200", response.httpStatusCode)) {
const body: Array<PromptSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PromptSummaryStatsDTO>", ""
) as Array<PromptSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
// Work around for missing responses in specification, e.g. for petstore.yaml
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
const body: Array<PromptSummaryStatsDTO> = ObjectSerializer.deserialize(
ObjectSerializer.parse(await response.body.text(), contentType),
"Array<PromptSummaryStatsDTO>", ""
) as Array<PromptSummaryStatsDTO>;
return new HttpInfo(response.httpStatusCode, response.headers, response.body, body);
}
throw new ApiException<string | Blob | undefined>(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers);
} | /**
* Unwraps the actual response sent by the server from the response context and deserializes the response content
* to the expected objects
*
* @params response Response returned by the server for a request to listPromptsByStatistic2
* @throws ApiException if the response code was not in [200, 299]
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/InteractiveStatisticsApi.ts#L1478-L1498 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | OrganizationApiRequestFactory.getOwners | public async getOwners(all?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// Path Params
const localVarPath = '/api/v2/org/owners';
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (all !== undefined) {
requestContext.setQueryParam("all", ObjectSerializer.serialize(all, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get the superior relationships of the current account, including direct and indirect owners, by default does not include virtual reported owners, so there will be no circular relationship.<br/>By specifying all=1, virtual reported owners can be returned, in this case, there may be a circular relationship.
* Get My Superior Relationship
* @param all Whether to return virtual reported owners
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/OrganizationApi.ts#L22-L52 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | OrganizationApiRequestFactory.getOwnersDot | public async getOwnersDot(all?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// Path Params
const localVarPath = '/api/v2/org/owners/dot';
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (all !== undefined) {
requestContext.setQueryParam("all", ObjectSerializer.serialize(all, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Same as /api/v2/org/owners, but returns a DOT format view, DOT reference: [graphviz](https://www.graphviz.org/)
* Get DOT of Superior Relationship
* @param all Whether to return virtual reported owners
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/OrganizationApi.ts#L59-L89 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
freechat | github_2023 | freechat-fun | typescript | OrganizationApiRequestFactory.getSubordinateOwners | public async getSubordinateOwners(username: string, all?: string, _options?: Configuration): Promise<RequestContext> {
let _config = _options || this.configuration;
// verify required parameter 'username' is not null or undefined
if (username === null || username === undefined) {
throw new RequiredError("OrganizationApi", "getSubordinateOwners", "username");
}
// Path Params
const localVarPath = '/api/v2/org/manage/{username}/owners'
.replace('{' + 'username' + '}', encodeURIComponent(String(username)));
// Make Request Context
const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET);
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8")
// Query Params
if (all !== undefined) {
requestContext.setQueryParam("all", ObjectSerializer.serialize(all, "string", ""));
}
let authMethod: SecurityAuthentication | undefined;
// Apply auth methods
authMethod = _config.authMethods["bearerAuth"]
if (authMethod?.applySecurityAuthentication) {
await authMethod?.applySecurityAuthentication(requestContext);
}
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
if (defaultAuth?.applySecurityAuthentication) {
await defaultAuth?.applySecurityAuthentication(requestContext);
}
return requestContext;
} | /**
* Get the superior relationship of the subordinate account, including direct and indirect owners, default does not include virtual reported owners, so there will be no circular relationship.<br/> By specifying all=1, virtual reported owners can be returned, in this case, there may be a circular relationship.
* Get Superior Relationship
* @param username The account being queried, must be a subordinate account of the current account
* @param all Whether to return virtual reported owners
*/ | https://github.com/freechat-fun/freechat/blob/cb80c3708b85cf52c02a91bdc0c9e9ddc14856db/freechat-sdk/typescript/apis/OrganizationApi.ts#L97-L134 | cb80c3708b85cf52c02a91bdc0c9e9ddc14856db |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.