Registers the Sarraf client (global, inject it with @InjectSarraf()) and a webhook controller at POST /webhooks/:provider. Create the app with { rawBody: true } so signatures can be checked.
Sarraf
@InjectSarraf()
POST /webhooks/:provider
{ rawBody: true }
@Module({ imports: [SarrafModule.forRoot({ client: { providers: { paymob: paymob({ ... }) } } })] })export class AppModule {} Copy
@Module({ imports: [SarrafModule.forRoot({ client: { providers: { paymob: paymob({ ... }) } } })] })export class AppModule {}
Static
Registers the
Sarrafclient (global, inject it with@InjectSarraf()) and a webhook controller atPOST /webhooks/:provider. Create the app with{ rawBody: true }so signatures can be checked.