import { FlairArray, FlairCsvResponse, FlairListResponse, FlairObject, FlairSelectorResponse, JsonStatus, } from '@devvit/protos';
import { Empty } from '@devvit/protos/types/google/protobuf/empty.js';
import { RedditAPI } from './RedditAPI.js';
export class Flair extends RedditAPI {
    async ClearFlairTemplates(request, metadata) {
        const response = await this._fetch('ClearFlairTemplates', request, metadata);
        return JsonStatus.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async DeleteFlair(request, metadata) {
        const response = await this._fetch('DeleteFlair', request, metadata);
        return JsonStatus.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async DeleteFlairTemplate(request, metadata) {
        const response = await this._fetch('DeleteFlairTemplate', request, metadata);
        return JsonStatus.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async Flair(request, metadata) {
        const response = await this._fetch('Flair', request, metadata);
        return JsonStatus.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async FlairTemplateOrder(request, metadata) {
        const _response = await this._fetch('FlairTemplateOrder', request, metadata);
        return Empty.fromJSON({});
    }
    async FlairConfig(request, metadata) {
        const response = await this._fetch('FlairConfig', request, metadata);
        return JsonStatus.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async FlairCsv(request, metadata) {
        const response = await this._fetch('FlairCsv', request, metadata);
        return FlairCsvResponse.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async FlairList(request, metadata) {
        const response = await this._fetch('FlairList', request, metadata);
        return FlairListResponse.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async FlairSelector(request, metadata) {
        const response = await this._fetch('FlairSelector', request, metadata);
        return FlairSelectorResponse.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async FlairTemplate(request, metadata) {
        const response = await this._fetch('FlairTemplate', request, metadata);
        return FlairObject.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async LinkFlair(request, metadata) {
        const response = await this._fetch('LinkFlair', request, metadata);
        return FlairArray.fromJSON({ flair: this._decodeAndValidateResponseJSON(response) });
    }
    async SelectFlair(request, metadata) {
        const response = await this._fetch('SelectFlair', request, metadata);
        return JsonStatus.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async SetFlairEnabled(request, metadata) {
        const response = await this._fetch('SetFlairEnabled', request, metadata);
        return JsonStatus.fromJSON(this._decodeAndValidateResponseJSON(response));
    }
    async UserFlair(request, metadata) {
        const response = await this._fetch('UserFlair', request, metadata);
        return FlairArray.fromJSON({ flair: this._decodeAndValidateResponseJSON(response) });
    }
}
