ethos-network-types
Version:
TypeScript types for Ethos Network API
1,319 lines • 360 kB
TypeScript
/**
* This file was auto-generated by openapi-typescript.
* Do not make direct changes to the file.
*/
export interface paths {
"/activities/{activityType}/{id}": {
/** Get activity by id */
get: operations["activity-byId"];
};
"/activities/bulk": {
/** Get activities by type and id */
post: operations["activity-bulk"];
};
"/activities/{activityType}/tx/{txHash}": {
/** Get activity by transaction hash */
get: operations["activity-byTxHash"];
};
"/activities/userkey": {
/** Get activities by userkey (author or subject) */
get: operations["activity-byUserkey"];
};
"/activities/feed": {
/** Get activities optimized for the feed */
post: operations["activity-feed"];
};
"/activities/notifications": {
/** Get activities for notifications feed */
post: operations["activity-notifications"];
};
"/activities/profile/given": {
/** Get activities authored by the specified user */
post: operations["activity-profileGiven"];
};
"/activities/profile/received": {
/** Get activities where the specified user is the subject */
post: operations["activity-profileReceived"];
};
"/activities/profile/all": {
/** Get all activities (authored & received) for a user */
post: operations["activity-profileAll"];
};
"/activities/project": {
/** Get project-related activities by project */
post: operations["activity-project"];
};
"/ai-images": {
/** List AI image jobs with pagination (Admin only) */
get: operations["aiImages-list"];
};
"/ai-images/{jobId}": {
/** Get AI image job details (Admin only) */
get: operations["aiImages-get"];
};
"/ai-images/selected": {
/** Get selected AI image job for entity */
get: operations["aiImages-getSelected"];
};
"/ai-images/regenerate": {
/** Regenerate AI image job (Admin only) */
post: operations["aiImages-regenerate"];
};
"/ai-images/activate": {
/** Activate AI image job as the image to use for an entity (Admin only) */
post: operations["aiImages-activate"];
};
"/ai-images/retry": {
/** Retry a failed AI image job (Admin only) */
post: operations["aiImages-retry"];
};
"/apps": {
/**
* List all applications with pagination and filtering
* @description Retrieve a paginated list of applications built on Ethos. Supports filtering by app type (APP, INTEGRATION, AGENT) and status (ACTIVE, INACTIVE).
*/
get: operations["apps-listApps"];
/** Create a new app */
post: operations["apps-createApp"];
};
"/apps/{id}": {
/** Get a specific app by ID */
get: operations["apps-getApp"];
};
"/apps/by-type/{appType}": {
/** Get apps by type */
get: operations["apps-getAppsByType"];
};
"/apps/{appId}": {
/** Update an existing app */
put: operations["apps-updateApp"];
/** Delete an app */
delete: operations["apps-deleteApp"];
};
"/categories": {
/** List categories */
get: operations["categories-listCategories"];
/** Create a new category */
post: operations["categories-createCategory"];
};
"/categories/{id}": {
/** Get a specific category by ID */
get: operations["categories-getCategory"];
};
"/categories/summaries/bulk": {
/** Get summaries for multiple categories */
get: operations["categories-getCategorySummariesBulk"];
};
"/categories/{categoryId}": {
/** Update an existing category */
put: operations["categories-updateCategory"];
/** Delete a category */
delete: operations["categories-deleteCategory"];
};
"/categories/{categoryId}/users": {
/** Get users belonging to a category */
get: operations["categories-getCategoryUsers"];
/** Add users to a category */
post: operations["categories-addUsersToCategory"];
/** Remove users from a category */
delete: operations["categories-removeUsersFromCategory"];
};
"/categories/{categoryId}/bulk-import": {
/** Bulk import users to a category via Twitter URLs */
post: operations["categories-bulkImportUsersToCategory"];
};
"/chains": {
/** List all available chains */
get: operations["chains-list"];
/** Add a new chain (Admin only) */
post: operations["chains-add"];
};
"/chains/{id}": {
/** Edit an existing chain (Admin only) */
put: operations["chains-edit"];
/** Delete a chain (Admin only) */
delete: operations["chains-delete"];
};
"/contributions/history": {
/** Get user contribution history */
get: operations["contributions-getHistory"];
};
"/healthcheck": {
/** Health check endpoint */
get: operations["healthcheck-unauthenticated"];
};
"/healthcheck/authenticated": {
/** Authenticated health check endpoint */
get: operations["healthcheck-authenticated"];
};
"/healthcheck/always-fail": {
/** Always fail health check endpoint with 418 teapot */
get: operations["healthcheck-alwaysFail"];
};
"/internal/users/{userkey}": {
/**
* Get user by userkey
* @description > ⚠️ **Warning:** This is an internal endpoint. It is **not guaranteed to be stable** and may change or break without notice.
*/
get: operations["internal-getUser"];
};
"/internal/listings": {
/**
* Get internal listings
* @description > ⚠️ **Warning:** This is an internal endpoint. It is **not guaranteed to be stable** and may change or break without notice.
*/
get: operations["internal-listings-getListingsPage"];
};
"/internal/listings/{username}": {
/**
* Get project details by username for listings page
* @description > ⚠️ **Warning:** This is an internal endpoint. It is **not guaranteed to be stable** and may change or break without notice.
*/
get: operations["internal-listings-getListingsProjectPage"];
};
"/invitations/check": {
/** Check if the current user is allowed to invite an address or ENS name */
get: operations["invitations-check"];
};
"/llm/translate": {
/** Get llm translation */
post: operations["llm-translate"];
};
"/markets": {
/** List markets with pagination, sorting, and filtering */
get: operations["markets-list"];
};
"/markets/featured": {
/** Get featured markets */
get: operations["markets-featured"];
};
"/markets/simulate-buy": {
/** Simulate trust market purchase */
post: operations["markets-simulateBuyVotes"];
};
"/nfts/user/{ethosUserKey}/owns-validator": {
/** Check if a user owns a validator NFT */
get: operations["nft-ownsValidator"];
};
"/nfts/user/{ethosUserKey}": {
/** Get NFTs owned by a user */
get: operations["nft-getNftsForUser"];
};
"/nfts/track": {
/** Track a new NFT collection (Admin only) */
post: operations["nft-trackNftCollection"];
};
"/projects": {
/** Show all listings projects based on filters, showing votes for current season */
get: operations["projects-list"];
};
"/projects/suggested": {
/** Get suggested listings projects for a user, showing votes for current season */
get: operations["projects-suggestedProjects"];
};
"/projects/{projectId}": {
/** Get a specific listing project by ID */
get: operations["projects-get"];
/** Update an existing project (Admin or Project Owner only) */
put: operations["projects-update"];
};
"/projects/{projectId}/details": {
/** Get detailed information for a specific project, showing votes for current season */
get: operations["projects-getDetails"];
};
"/projects/username/{username}": {
/** Get detailed information for a specific project by username, showing votes for current season */
get: operations["projects-getDetailsByUsername"];
};
"/projects/{projectId}/team": {
/** Show team members for a listings project */
get: operations["projects-getTeamMembers"];
/** Add team members to a project (Admin or Project Owner only) */
post: operations["projects-addTeamMember"];
/** Remove a team member from a project (Admin or Project Owner only) */
delete: operations["projects-removeTeamMember"];
};
"/projects/{projectId}/chains": {
/** Add a chain to a project (Admin or Project Owner only) */
post: operations["projects-addChain"];
/** Remove a chain from a project (Admin or Project Owner only) */
delete: operations["projects-removeChain"];
};
"/projects/confirm": {
/** Confirm project creation using a token (Admin only) */
get: operations["projects-confirmCreation"];
};
"/projects/{projectId}/votes": {
/** Cast a vote for a listings project */
post: operations["projectVotes-castVote"];
};
"/projects/votes/balance": {
/** Get the current user's vote balance, optionally for a specific listings project and season */
get: operations["projectVotes-getUserVoteBalance"];
};
"/projects/{projectId}/voters": {
/**
* Get paginated list of project voters with their vote statistics and totals
* @description **Time Scope Options (scope parameter):**
* - `scope=global`: All-time data from first vote to present
* - `scope=global-dates`: Custom date range (requires startDate & endDate)
* - `scope=current-period`: Current voting period (default - backend determines automatically)
* - `scope=period`: Specific voting period (requires year & period)
*
* **Parameter Requirements by Scope:**
* - `global`: No additional parameters needed
* - `global-dates`: Requires `startDate` and `endDate` (ISO date strings)
* - `current-period`: No additional parameters needed (default)
* - `period`: Requires `year` (number) and `period` (number)
*
*
* **Examples:**
* - All-time: `GET /projects/123/voters?scope=global`
* - Date range: `GET /projects/123/voters?scope=global-dates&startDate=2024-01-01&endDate=2024-12-31`
* - Current period: `GET /projects/123/voters` (default) or `GET /projects/123/voters?scope=current-period`
* - Specific period: `GET /projects/123/voters?scope=period&year=2024&period=3`
*
* **Notes:**
* - End dates extending into the future are automatically capped to the current time
* - Global scope uses all historical data for the project
*/
get: operations["projectVotes-getProjectVoters"];
};
"/projects/votes/reallocate": {
/** Reallocate votes for all users (Admin only) */
post: operations["projectVotes-reallocateVotes"];
};
"/projects/votes/bulk-totals": {
/**
* Get bulk user project vote totals with flexible time range support
* @description **Time Scope Options (scope parameter):**
* - `scope=global`: All-time data from first vote to present
* - `scope=global-dates`: Custom date range (requires startDate & endDate)
* - `scope=current-period`: Current voting period (default - backend determines automatically)
* - `scope=period`: Specific voting period (requires year & period)
*
* **Parameter Requirements by Scope:**
* - `global`: No additional parameters needed
* - `global-dates`: Requires `startDate` and `endDate` (ISO date strings)
* - `current-period`: No additional parameters needed (default)
* - `period`: Requires `year` (number) and `period` (number)
*
*
* **Examples:**
* - All-time: `GET /projects/PROJECT_ID/bulk-totals?scope=global`
* - Date range: `GET /projects/PROJECT_ID/bulk-totals?scope=global-dates&startDate=2024-01-01&endDate=2024-12-31`
* - Current period: `GET /projects/PROJECT_ID/bulk-totals` (default) or `GET /projects/PROJECT_ID/bulk-totals?scope=current-period`
* - Specific period: `GET /projects/PROJECT_ID/bulk-totals?scope=period&year=2024&period=3`
*
* **Notes:**
* - End dates extending into the future are automatically capped to the current time
* - Global scope uses all historical data for the project
*/
get: operations["projectVotes-getBulkUserProjectVoteTotals"];
};
"/projects/{projectId}/chart": {
/**
* Get project vote chart data with flexible time range and aggregation options
* @description **Time Scope Options (scope parameter):**
* - `scope=global`: All-time data from first vote to present
* - `scope=global-dates`: Custom date range (requires startDate & endDate)
* - `scope=current-period`: Current voting period (default - backend determines automatically)
* - `scope=period`: Specific voting period (requires year & period)
*
* **Parameter Requirements by Scope:**
* - `global`: No additional parameters needed
* - `global-dates`: Requires `startDate` and `endDate` (ISO date strings)
* - `current-period`: No additional parameters needed (default)
* - `period`: Requires `year` (number) and `period` (number)
*
* **Time Aggregation (bucket parameter):**
* - Available buckets: '1 minute', '5 minutes', '15 minutes', '30 minutes', '1 hour', '2 hours', '6 hours', '12 hours', '1 day', '1 week', '1 month'
* - If bucket is omitted, the API auto-selects an optimal bucket size based on the time range to prevent excessive data points
* - For large time spans with small buckets, an error will be returned with a suggested larger bucket
* - Maximum data points: 2000 (for performance)
*
* **Examples:**
* - All-time: `GET /projects/123/chart?scope=global`
* - Date range: `GET /projects/123/chart?scope=global-dates&startDate=2024-01-01&endDate=2024-12-31`
* - Current period: `GET /projects/123/chart` (default) or `GET /projects/123/chart?scope=current-period`
* - Specific period: `GET /projects/123/chart?scope=period&year=2024&period=3`
*
* **Notes:**
* - End dates extending into the future are automatically capped to the current time
* - Global scope uses all historical data for the project
*/
get: operations["projectVotes-getProjectVoteChart"];
};
"/reviews/count/between": {
/** Count reviews left from one user to another */
get: operations["reviews-count"];
};
"/reviews/latest/between": {
/** Get the latest review from one user to another */
get: operations["reviews-latest"];
};
"/score/address": {
/** Get score by address */
get: operations["score-byAddress"];
};
"/score/addresses": {
/** Get scores by multiple addresses */
post: operations["score-bulkByAddresses"];
};
"/score/userId": {
/** Get score by userId */
get: operations["score-byUserId"];
};
"/score/userIds": {
/** Get scores by multiple userIds */
post: operations["score-bulkByUserIds"];
};
"/score/userkey": {
/** Get score by userkey */
get: operations["score-byUserKey"];
};
"/score/userkeys": {
/** Get scores by multiple userkeys */
post: operations["score-bulkByUserKeys"];
};
"/score/status": {
/** Check score calculation status */
get: operations["score-status"];
};
"/users/by/ids": {
/** Get multiple users by user IDs */
post: operations["users-getByIds"];
};
"/users/by/address": {
/** Get multiple users by Ethereum addresses */
post: operations["users-getByAddresses"];
};
"/users/by/profile-id": {
/** Get multiple users by profile IDs */
post: operations["users-getByProfileIds"];
};
"/users/by/x": {
/** Get multiple users by Twitter/X account IDs or usernames */
post: operations["users-getByTwitterAccounts"];
};
"/users/by/discord": {
/** Get multiple users by Discord user IDs */
post: operations["users-getByDiscordAccounts"];
};
"/users/by/farcaster": {
/** Get multiple users by Farcaster user IDs */
post: operations["users-getByFarcasterAccounts"];
};
"/users/by/farcaster/usernames": {
/**
* Get multiple users by Farcaster usernames
* @description Bulk lookup of users by Farcaster usernames. Results are categorized into three arrays:
*
* • "users": Successfully matched usernames with their Ethos user data
*
* • "notFoundUsernames": Valid usernames with no associated Ethos users
*
* • "errorUsernames": Usernames that failed lookup due to network/API errors
*
* Both "users" and "notFoundUsernames" results can be cached safely.
*/
post: operations["users-getByFarcasterUsernames"];
};
"/users/by/telegram": {
/** Get multiple users by Telegram user IDs */
post: operations["users-getByTelegramAccounts"];
};
"/users/search": {
/** Search users by query string */
get: operations["users-search"];
};
"/user/{userId}": {
/** Get a specific user by user ID */
get: operations["users-get"];
};
"/user/by/address/{address}": {
/** Get a user by Ethereum address */
get: operations["users-getByAddress"];
};
"/user/by/profile-id/{profileId}": {
/** Get a user by profile ID */
get: operations["users-getByProfileId"];
};
"/user/by/username/{username}": {
/** Get a user by username */
get: operations["users-getByUsername"];
};
"/user/by/x/{accountIdOrUsername}": {
/** Get a user by Twitter/X account ID or username */
get: operations["users-getByTwitter"];
};
"/user/by/discord/{discordUserId}": {
/** Get a user by Discord user ID */
get: operations["users-getByDiscord"];
};
"/user/by/farcaster/{farcasterUserId}": {
/** Get a user by Farcaster user ID */
get: operations["users-getByFarcaster"];
};
"/user/by/farcaster/username/{farcasterUsername}": {
/** Get a user by Farcaster username */
get: operations["users-getByFarcasterUsername"];
};
"/user/by/telegram/{telegramUserId}": {
/** Get a user by Telegram user ID */
get: operations["users-getByTelegram"];
};
"/users/{userkey}/categories": {
/** Get overall position on leaderboard and position in each category for user */
get: operations["users-getUserRanksAmongCategories"];
};
"/users/refresh/twitter": {
/** Refresh x.com profile details like name, avatar, etc. */
post: operations["users-refreshUser"];
};
"/users/{userkey}/refresh/twitter": {
/** Refresh x.com profile details like name, avatar, etc. */
post: operations["users-adminRefreshUser"];
};
"/votes": {
/** Get votes for an activity */
get: operations["votes-getVotes"];
};
"/votes/stats": {
/** Get aggregated vote stats for a single activity */
get: operations["votes-getVotesStats"];
/** Get aggregated vote stats for multiple activities */
post: operations["votes-getBulkVotesStats"];
};
"/admin/xp/weekly/stats": {
/** Get detailed weekly XP statistics for specified users (Admin only) */
get: operations["weeklyXp-getWeeklyStats"];
};
"/admin/xp/weekly/active-users": {
/** Get user IDs that were active in the specified date range (Admin only) */
get: operations["weeklyXp-getActiveUserIds"];
};
"/xp/user/{userkey}": {
/** Get total XP for a user across all seasons */
get: operations["xp-userTotalXp"];
};
"/xp/user/{userkey}/season/{seasonId}": {
/** Get XP for a user in a specific season */
get: operations["xp-userSeasonXp"];
};
"/xp/user/{userkey}/season/{seasonId}/weekly": {
/** Get weekly XP data for a user in a specific season */
get: operations["xp-userWeeklySeasonXp"];
};
"/xp/seasons": {
/** Get all XP seasons plus current season information */
get: operations["xp-seasons"];
};
"/xp/season/{seasonId}/weeks": {
/** Get all weeks in a season with their date ranges */
get: operations["xp-weeksBySeason"];
};
"/xp/user/{userkey}/leaderboard-rank": {
/** Get leaderboard rank for a user */
get: operations["xp-userLeaderboardRank"];
};
}
export type webhooks = Record<string, never>;
export interface components {
schemas: {
/**
* Invalid input data error (400)
* @description The error information
* @example {
* "code": "BAD_REQUEST",
* "message": "Invalid input data",
* "issues": []
* }
*/
"error.BAD_REQUEST": {
/**
* @description The error message
* @example Invalid input data
*/
message: string;
/**
* @description The error code
* @example BAD_REQUEST
*/
code: string;
/**
* @description An array of issues that were responsible for the error
* @example []
*/
issues?: {
message: string;
}[];
};
/**
* Not found error (404)
* @description The error information
* @example {
* "code": "NOT_FOUND",
* "message": "Not found",
* "issues": []
* }
*/
"error.NOT_FOUND": {
/**
* @description The error message
* @example Not found
*/
message: string;
/**
* @description The error code
* @example NOT_FOUND
*/
code: string;
/**
* @description An array of issues that were responsible for the error
* @example []
*/
issues?: {
message: string;
}[];
};
/**
* Internal server error error (500)
* @description The error information
* @example {
* "code": "INTERNAL_SERVER_ERROR",
* "message": "Internal server error",
* "issues": []
* }
*/
"error.INTERNAL_SERVER_ERROR": {
/**
* @description The error message
* @example Internal server error
*/
message: string;
/**
* @description The error code
* @example INTERNAL_SERVER_ERROR
*/
code: string;
/**
* @description An array of issues that were responsible for the error
* @example []
*/
issues?: {
message: string;
}[];
};
/**
* Authorization not provided error (401)
* @description The error information
* @example {
* "code": "UNAUTHORIZED",
* "message": "Authorization not provided",
* "issues": []
* }
*/
"error.UNAUTHORIZED": {
/**
* @description The error message
* @example Authorization not provided
*/
message: string;
/**
* @description The error code
* @example UNAUTHORIZED
*/
code: string;
/**
* @description An array of issues that were responsible for the error
* @example []
*/
issues?: {
message: string;
}[];
};
/**
* Insufficient access error (403)
* @description The error information
* @example {
* "code": "FORBIDDEN",
* "message": "Insufficient access",
* "issues": []
* }
*/
"error.FORBIDDEN": {
/**
* @description The error message
* @example Insufficient access
*/
message: string;
/**
* @description The error code
* @example FORBIDDEN
*/
code: string;
/**
* @description An array of issues that were responsible for the error
* @example []
*/
issues?: {
message: string;
}[];
};
};
responses: never;
parameters: never;
requestBodies: never;
headers: never;
pathItems: never;
}
export type $defs = Record<string, never>;
export type external = Record<string, never>;
export interface operations {
/** Get activity by id */
"activity-byId": {
parameters: {
path: {
activityType: "attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote";
id: number;
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": unknown;
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Not found */
404: {
content: {
"application/json": components["schemas"]["error.NOT_FOUND"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get activities by type and id */
"activity-bulk": {
requestBody: {
content: {
"application/json": {
/** @enum {string} */
activityType: "attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote";
id: number;
};
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": unknown[];
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get activity by transaction hash */
"activity-byTxHash": {
parameters: {
path: {
activityType: "attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote";
txHash: string;
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": unknown;
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Not found */
404: {
content: {
"application/json": components["schemas"]["error.NOT_FOUND"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get activities by userkey (author or subject) */
"activity-byUserkey": {
parameters: {
query: {
userkey: string;
direction?: "author" | "subject";
activityType?: ("PROFILE" | "ATTESTATION" | "INVITATION" | "VOUCH" | "SLASH" | "REVIEW" | "MARKET" | "MARKET_VOTE" | "VOTE" | "REPLY" | "CLAIM" | "PROJECT")[];
orderBy?: "createdAt" | "totalVotes" | "netVotes" | "replyCount" | "authorScore" | "subjectScore" | "votes";
sort?: "asc" | "desc";
includeArchived?: boolean;
limit?: number;
offset?: number;
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": unknown[];
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Not found */
404: {
content: {
"application/json": components["schemas"]["error.NOT_FOUND"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get activities optimized for the feed */
"activity-feed": {
requestBody: {
content: {
"application/json": {
filter?: ("attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote")[];
/** @default false */
cache?: boolean;
/** @default null */
dayRange?: number | null;
/**
* @default {
* "field": "timestamp",
* "direction": "desc"
* }
*/
orderBy?: {
/** @enum {string} */
field: "timestamp" | "votes" | "comments" | "score" | "controversial" | "hot" | "distance";
/** @enum {string} */
direction: "asc" | "desc";
};
/** @default 50 */
limit?: number;
/** @default 0 */
offset?: number;
};
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
values: unknown[];
total: number;
limit: number;
offset: number;
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get activities for notifications feed */
"activity-notifications": {
requestBody: {
content: {
"application/json": {
filter?: ("attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote")[];
excludeHistorical?: boolean;
pagination: {
/** @default 50 */
limit?: number;
/** @default 0 */
offset?: number;
};
/**
* @default {
* "field": "timestamp",
* "direction": "desc"
* }
*/
orderBy?: {
/** @enum {string} */
field: "timestamp" | "votes" | "comments" | "score" | "controversial" | "hot" | "distance";
/** @enum {string} */
direction: "asc" | "desc";
};
};
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
values: unknown[];
total: number;
limit: number;
offset: number;
offsets?: {
attestation?: number;
"closed-slash"?: number;
"invitation-accepted"?: number;
market?: number;
"market-vote"?: number;
"open-slash"?: number;
project?: number;
review?: number;
slash?: number;
unvouch?: number;
vouch?: number;
vote?: number;
};
counts?: {
attestation?: number;
"closed-slash"?: number;
"invitation-accepted"?: number;
market?: number;
"market-vote"?: number;
"open-slash"?: number;
project?: number;
review?: number;
slash?: number;
unvouch?: number;
vouch?: number;
vote?: number;
};
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Authorization not provided */
401: {
content: {
"application/json": components["schemas"]["error.UNAUTHORIZED"];
};
};
/** @description Insufficient access */
403: {
content: {
"application/json": components["schemas"]["error.FORBIDDEN"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get activities authored by the specified user */
"activity-profileGiven": {
requestBody: {
content: {
"application/json": {
userkey: string;
filter?: ("attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote")[];
excludeHistorical?: boolean;
/**
* @default {
* "field": "timestamp",
* "direction": "desc"
* }
*/
orderBy?: {
/** @enum {string} */
field: "timestamp" | "votes" | "comments" | "score" | "controversial" | "hot" | "distance";
/** @enum {string} */
direction: "asc" | "desc";
};
/** @default 50 */
limit?: number;
/** @default 0 */
offset?: number;
};
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
values: unknown[];
total: number;
limit: number;
offset: number;
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get activities where the specified user is the subject */
"activity-profileReceived": {
requestBody: {
content: {
"application/json": {
userkey: string;
filter?: ("attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote")[];
excludeHistorical?: boolean;
/**
* @default {
* "field": "timestamp",
* "direction": "desc"
* }
*/
orderBy?: {
/** @enum {string} */
field: "timestamp" | "votes" | "comments" | "score" | "controversial" | "hot" | "distance";
/** @enum {string} */
direction: "asc" | "desc";
};
/** @default 50 */
limit?: number;
/** @default 0 */
offset?: number;
};
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
values: unknown[];
total: number;
limit: number;
offset: number;
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get all activities (authored & received) for a user */
"activity-profileAll": {
requestBody: {
content: {
"application/json": {
userkey: string;
filter?: ("attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote")[];
excludeHistorical?: boolean;
/**
* @default {
* "field": "timestamp",
* "direction": "desc"
* }
*/
orderBy?: {
/** @enum {string} */
field: "timestamp" | "votes" | "comments" | "score" | "controversial" | "hot" | "distance";
/** @enum {string} */
direction: "asc" | "desc";
};
/** @default 50 */
limit?: number;
/** @default 0 */
offset?: number;
};
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
values: unknown[];
total: number;
limit: number;
offset: number;
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get project-related activities by project */
"activity-project": {
requestBody: {
content: {
"application/json": {
userkey: string;
filter?: ("attestation" | "closed-slash" | "invitation-accepted" | "market" | "market-vote" | "open-slash" | "project" | "review" | "slash" | "unvouch" | "vouch" | "vote")[];
excludeHistorical?: boolean;
/**
* @default {
* "field": "timestamp",
* "direction": "desc"
* }
*/
orderBy?: {
/** @enum {string} */
field: "timestamp" | "votes" | "comments" | "score" | "controversial" | "hot" | "distance";
/** @enum {string} */
direction: "asc" | "desc";
};
/** @default 50 */
limit?: number;
/** @default 0 */
offset?: number;
};
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
values: unknown[];
total: number;
limit: number;
offset: number;
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** List AI image jobs with pagination (Admin only) */
"aiImages-list": {
parameters: {
query?: {
status?: "PENDING" | "PROCESSING" | "COMPLETED" | "FAILED";
jobType?: "SLASH" | "BROKER";
limit?: number;
offset?: number;
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
values: ({
id: number;
/** @enum {string} */
jobType: "SLASH" | "BROKER";
entityId: number;
/** @enum {string} */
status: "PENDING" | "PROCESSING" | "COMPLETED" | "FAILED";
error: string | null;
metadata?: unknown;
createdAt: string;
updatedAt: string;
completedAt: string | null;
AiImages: {
id: number;
jobId: number;
fileName: string;
imageUrl: string;
metadata?: unknown;
createdAt: string;
}[];
})[];
total: number;
limit: number;
offset: number;
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Authorization not provided */
401: {
content: {
"application/json": components["schemas"]["error.UNAUTHORIZED"];
};
};
/** @description Insufficient access */
403: {
content: {
"application/json": components["schemas"]["error.FORBIDDEN"];
};
};
/** @description Not found */
404: {
content: {
"application/json": components["schemas"]["error.NOT_FOUND"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get AI image job details (Admin only) */
"aiImages-get": {
parameters: {
path: {
jobId: number;
};
};
responses: {
/** @description Successful response */
200: {
content: {
"application/json": {
id: number;
/** @enum {string} */
jobType: "SLASH" | "BROKER";
entityId: number;
/** @enum {string} */
status: "PENDING" | "PROCESSING" | "COMPLETED" | "FAILED";
error: string | null;
metadata?: unknown;
createdAt: string;
updatedAt: string;
completedAt: string | null;
AiImages: {
id: number;
jobId: number;
fileName: string;
imageUrl: string;
metadata?: unknown;
createdAt: string;
}[];
};
};
};
/** @description Invalid input data */
400: {
content: {
"application/json": components["schemas"]["error.BAD_REQUEST"];
};
};
/** @description Authorization not provided */
401: {
content: {
"application/json": components["schemas"]["error.UNAUTHORIZED"];
};
};
/** @description Insufficient access */
403: {
content: {
"application/json": components["schemas"]["error.FORBIDDEN"];
};
};
/** @description Not found */
404: {
content: {
"application/json": components["schemas"]["error.NOT_FOUND"];
};
};
/** @description Internal server error */
500: {
content: {
"application/json": components["schemas"]["error.INTERNAL_SERVER_ERROR"];
};
};
};
};
/** Get selected AI image job for entity */
"aiImages-getS