icns-frontend/types/api-response.ts

36 lines
719 B
TypeScript
Raw Normal View History

import { TwitterPublicMetrics } from "../pages/api/twitter-auth-info";
2022-12-05 11:01:24 +00:00
export interface TwitterAuthUrlResponse {
authUrl: string;
}
export interface TwitterAuthInfoResponse {
accessToken: string;
id: string;
name: string;
username: string;
profile_image_url: string;
description: string;
public_metrics: TwitterPublicMetrics;
2022-12-05 11:01:24 +00:00
}
2022-12-05 15:02:30 +00:00
export interface IcnsVerificationResponse {
2022-12-12 06:31:52 +00:00
verificationList: (
| {
status: "fulfilled";
value: {
errors: Error[];
data: {
verifying_msg: string;
signature: number[];
algorithm: string;
};
};
}
| {
status: "rejected";
reason: Error;
}
)[];
}