0.2.3 • Published 1 year ago

@octacondeveloper/ajala v0.2.3

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

NestJS AJALA

Description

An axios wrapper for Nest originally published as part of the @nestjs/common package. This package is a developed for making http calls for glade internal services.

Installation

$ npm i --save @octacondeveloper/ajala

Quick Start

Once the installation process is complete, to use the AjalaService, first import AjalaModule.

@Module({
  imports: [AjalaModule],
  providers: [AppService],
})
export class AppModule {}

Next, inject AjalaService using normal constructor injection.

@Injectable()
export class AppService {
  constructor(private readonly ajalaService: AjalaService) {}

  async findAll(): Promise<any>  {
    return await this.ajalaService.get("https://jsonplaceholder.typicode.com/posts/11", [], body, false, null);
  }
//sample payload structure
//this.ajalaService.get(url, header, body, proxy, options)
}

Other methods include

this.ajalaService.get("https://jsonplaceholder.typicode.com/posts/11",  [], body,  false,  null);
this.ajalaService.delete("https://jsonplaceholder.typicode.com/posts/11",  [], body,  false,  null);
this.ajalaService.put("https://jsonplaceholder.typicode.com/posts/11",  [], body,  false,  null);
this.ajalaService.patch("https://jsonplaceholder.typicode.com/posts/11",  [], body,  false,  null);
this.ajalaService.head("https://jsonplaceholder.typicode.com/posts/11",  [], body,  false,  null);
this.ajalaService.post("https://jsonplaceholder.typicode.com/posts/11",  [], body,  false,  null, files);

License

Ajala is MIT licensed.

0.2.3

1 year ago

0.2.2

1 year ago

0.2.1

1 year ago

0.2.0

1 year ago

0.1.9

1 year ago

0.1.8

1 year ago

0.1.7

1 year ago

0.1.6

1 year ago

0.1.5

1 year ago

0.1.4

1 year ago

0.1.3

1 year ago

0.1.2

1 year ago

0.1.1

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago