Skip to content

Commit

Permalink
Merge branch 'VOC-203-implementing-custom-api-endpoints-for-product-c…
Browse files Browse the repository at this point in the history
…onfiguration' into 'master'

VOC-203-implementing-custom-api-endpoints-for-product-configuration

See merge request shockbyte/shared/whmcs-node!4
  • Loading branch information
damieneichhorn committed Nov 8, 2023
2 parents 244b770 + 3363531 commit 54abb44
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules
dist
dist
.idea/
2 changes: 2 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import { WhmcsSupportService } from "./module/support";
import { WhmcsSystemService } from "./module/system";
import { WhmcsTicketsService } from "./module/tickets";
import { WhmcsUsersService } from "./module/users";
import { WhmcsClientCustom } from "./module/custom";

export default class WhmcsApi {

Expand All @@ -40,4 +41,5 @@ export default class WhmcsApi {
public system: WhmcsSystemService = new WhmcsSystemService;
public tickets: WhmcsTicketsService = new WhmcsTicketsService;
public users: WhmcsUsersService = new WhmcsUsersService;
public custom: WhmcsClientCustom = new WhmcsClientCustom;
}
7 changes: 7 additions & 0 deletions src/module/custom.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import {BaseModule} from "./base";

export class WhmcsClientCustom extends BaseModule {
public async call<T>(method: string, options: Record<string, unknown>): Promise<T> {
return this.request(method, options);
}
}

0 comments on commit 54abb44

Please sign in to comment.