Skip to content

Commit

Permalink
Add typings for the social_service_account resource
Browse files Browse the repository at this point in the history
Depends-on: balena-io/balena-api#4623
Change-type: minor
  • Loading branch information
thgreasi committed Sep 22, 2023
1 parent 4e54ae8 commit 9d001d6
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/types/jwt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export interface JWTUser {
social_service_account?: SocialServiceAccount[];
}

export interface SocialServiceAccount {
interface SocialServiceAccount {
provider: string;
display_name: string;
}
11 changes: 10 additions & 1 deletion src/types/models.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ export interface ResourceTypeMap {
service_environment_variable: ServiceEnvironmentVariable;
service_install: ServiceInstall;
service_instance: ServiceInstance;
social_service_account: SocialServiceAccount;
subscription: Subscription;
subscription_addon_discount: SubscriptionAddonDiscount;
subscription_prepaid_addon: SubscriptionPrepaidAddon;
Expand Down Expand Up @@ -406,7 +407,7 @@ export interface Device {
last_vpn_event: string;
latitude?: string;
local_id?: string;
location: string;
location?: string;
longitude?: string;
note: string;
os_variant?: string;
Expand Down Expand Up @@ -571,6 +572,14 @@ export interface SSHKey {
user: NavigationResource<User>;
}

export interface SocialServiceAccount {
// TODO: improve the custom pine client rypings to support resources w/o an id field
id: undefined;
belongs_to__user: NavigationResource<User>;
display_name: string | null;
provider: string;
}

export interface ImageInstall {
id: number;
download_progress: number | null;
Expand Down

0 comments on commit 9d001d6

Please sign in to comment.