Developer Preview — This project is in active development. APIs may change. Provide feedback
Skip to content

@salesforce/b2c-tooling-sdk / clients / createAuthMiddleware

Function: createAuthMiddleware()

createAuthMiddleware(auth): Middleware

Defined in: packages/b2c-tooling-sdk/src/clients/middleware.ts:50

Creates authentication middleware for openapi-fetch.

This middleware intercepts requests and adds OAuth authentication headers using the provided AuthStrategy.

Parameters

auth

AuthStrategy

The authentication strategy to use

Returns

Middleware

Middleware that adds auth headers to requests

All rights reserved.