@gymspace/sdk 1.1.1 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/client.ts CHANGED
@@ -20,6 +20,10 @@ export class ApiClient {
20
20
  private config: GymSpaceConfig;
21
21
  private refreshToken: string | null = null;
22
22
 
23
+ public getAccessToken(): string | null {
24
+ return this.config.apiKey || null;
25
+ }
26
+
23
27
  constructor(config: GymSpaceConfig) {
24
28
  this.config = config;
25
29
 
@@ -68,7 +72,6 @@ export class ApiClient {
68
72
  );
69
73
  }
70
74
 
71
-
72
75
  private handleError(error: AxiosError): GymSpaceError {
73
76
  const requestPath = error.config?.url || 'unknown';
74
77
  const method = error.config?.method?.toUpperCase() || 'unknown';
@@ -78,6 +78,12 @@ export interface Client {
78
78
  evaluations: number;
79
79
  checkIns: number;
80
80
  };
81
+ hasCheckedInToday?: boolean;
82
+ lastCheckIn?: {
83
+ id: string;
84
+ timestamp: string;
85
+ createdAt: string;
86
+ };
81
87
  }
82
88
 
83
89
  export interface ClientStat {
@@ -124,6 +130,8 @@ export interface SearchClientsParams extends PaginationQueryDto {
124
130
  clientNumber?: string;
125
131
  documentId?: string;
126
132
  includeContractStatus?: boolean;
133
+ notCheckedInToday?: boolean;
134
+ checkedInToday?: boolean;
127
135
  }
128
136
 
129
137
  export interface ClientSearchForCheckInResponse {
package/src/sdk.ts CHANGED
@@ -26,7 +26,7 @@ import {
26
26
  } from './resources';
27
27
 
28
28
  export class GymSpaceSdk {
29
- private client: ApiClient;
29
+ public client: ApiClient;
30
30
 
31
31
  // Resources
32
32
  public auth: AuthResource;