-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: HTSFA-771 - Remove the exercise flow component from the SDK (…
…#54) * HTSFA-771 * update API
- Loading branch information
1 parent
0a90bba
commit c154594
Showing
86 changed files
with
599 additions
and
7,161 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
112 changes: 112 additions & 0 deletions
112
projects/angular-sdk/src/apis/hopper-cloud-airline/v1/api/analytics.service.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,112 @@ | ||
/** | ||
* Airline API | ||
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) | ||
* | ||
* OpenAPI spec version: v1.1 | ||
* | ||
* | ||
* NOTE: This class is auto generated by the swagger code generator program. | ||
* https://github.com/swagger-api/swagger-codegen.git | ||
* Do not edit the class manually. | ||
*//* tslint:disable:no-unused-variable member-ordering */ | ||
|
||
import { Inject, Injectable, Optional } from '@angular/core'; | ||
import { HttpClient, HttpHeaders, HttpParams, | ||
HttpResponse, HttpEvent } from '@angular/common/http'; | ||
import { CustomHttpUrlEncodingCodec } from '../encoder'; | ||
|
||
import { Observable } from 'rxjs'; | ||
|
||
import { BadRequest } from '../model/badRequest'; | ||
import { CfarEvent } from '../model/cfarEvent'; | ||
import { UnprocessableEntity } from '../model/unprocessableEntity'; | ||
|
||
import { BASE_PATH, COLLECTION_FORMATS } from '../variables'; | ||
import { Configuration } from '../configuration'; | ||
|
||
|
||
@Injectable() | ||
export class AnalyticsService { | ||
|
||
protected basePath = '/airline/v1.1'; | ||
public defaultHeaders = new HttpHeaders(); | ||
public configuration = new Configuration(); | ||
|
||
constructor(protected httpClient: HttpClient, @Optional()@Inject(BASE_PATH) basePath: string, @Optional() configuration: Configuration) { | ||
if (basePath) { | ||
this.basePath = basePath; | ||
} | ||
if (configuration) { | ||
this.configuration = configuration; | ||
this.basePath = basePath || configuration.basePath || this.basePath; | ||
} | ||
} | ||
|
||
/** | ||
* @param consumes string[] mime-types | ||
* @return true: consumes contains 'multipart/form-data', false: otherwise | ||
*/ | ||
private canConsumeForm(consumes: string[]): boolean { | ||
const form = 'multipart/form-data'; | ||
for (const consume of consumes) { | ||
if (form === consume) { | ||
return true; | ||
} | ||
} | ||
return false; | ||
} | ||
|
||
|
||
/** | ||
* Send a Frontend Event | ||
* Events can also be sent directly from a frontend running on end customer's device using the session ID | ||
* @param body | ||
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. | ||
* @param reportProgress flag to report request and response progress. | ||
*/ | ||
public postCustomerEvents(body: CfarEvent, observe?: 'body', reportProgress?: boolean): Observable<any>; | ||
public postCustomerEvents(body: CfarEvent, observe?: 'response', reportProgress?: boolean): Observable<HttpResponse<any>>; | ||
public postCustomerEvents(body: CfarEvent, observe?: 'events', reportProgress?: boolean): Observable<HttpEvent<any>>; | ||
public postCustomerEvents(body: CfarEvent, observe: any = 'body', reportProgress: boolean = false ): Observable<any> { | ||
|
||
if (body === null || body === undefined) { | ||
throw new Error('Required parameter body was null or undefined when calling postCustomerEvents.'); | ||
} | ||
|
||
let headers = this.defaultHeaders; | ||
|
||
// authentication (SessionAuth) required | ||
if (this.configuration.apiKeys && this.configuration.apiKeys["HC-Session-ID"]) { | ||
headers = headers.set('HC-Session-ID', this.configuration.apiKeys["HC-Session-ID"]); | ||
} | ||
|
||
// to determine the Accept header | ||
let httpHeaderAccepts: string[] = [ | ||
'application/json' | ||
]; | ||
const httpHeaderAcceptSelected: string | undefined = this.configuration.selectHeaderAccept(httpHeaderAccepts); | ||
if (httpHeaderAcceptSelected != undefined) { | ||
headers = headers.set('Accept', httpHeaderAcceptSelected); | ||
} | ||
|
||
// to determine the Content-Type header | ||
const consumes: string[] = [ | ||
'application/json' | ||
]; | ||
const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes); | ||
if (httpContentTypeSelected != undefined) { | ||
headers = headers.set('Content-Type', httpContentTypeSelected); | ||
} | ||
|
||
return this.httpClient.request<any>('post',`${this.basePath}/customer/events`, | ||
{ | ||
body: body, | ||
withCredentials: this.configuration.withCredentials, | ||
headers: headers, | ||
observe: observe, | ||
reportProgress: reportProgress | ||
} | ||
); | ||
} | ||
|
||
} |
8 changes: 5 additions & 3 deletions
8
projects/angular-sdk/src/apis/hopper-cloud-airline/v1/api/api.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
export * from './customer.service'; | ||
import { CustomerService } from './customer.service'; | ||
export const APIS = [CustomerService]; | ||
export * from './analytics.service'; | ||
import { AnalyticsService } from './analytics.service'; | ||
export * from './cancelForAnyReasonCFAR.service'; | ||
import { CancelForAnyReasonCFARService } from './cancelForAnyReasonCFAR.service'; | ||
export const APIS = [AnalyticsService, CancelForAnyReasonCFARService]; |
Oops, something went wrong.