> ## Documentation Index
> Fetch the complete documentation index at: https://docs.agentium.in/llms.txt
> Use this file to discover all available pages before exploring further.

# Identity and authorization

> Public identity and authorization signatures and configuration in @agentium/transport 4.0.0.

Import these **4 exports** from `@agentium/transport`. Read the [identity and authorization guide](/ship/authentication) for setup and behavior, or return to the [package reference](/api-reference/transport).

A `?` marks an optional field. These are declarations for lookup; run the examples in the linked guide. Follow related-type links for Agentium types and source links for imported dependency types.

## createJwtMiddleware

[Source](https://github.com/agentiumOS/agentium/blob/v4.0.0/packages/transport/src/express/jwt-middleware.ts)

```typescript theme={null}
export declare function createJwtMiddleware(config: JwtConfig): (req: any, res: any, next: any) => any;
```

Related: [`JwtConfig`](/api-reference/transport/authentication#jwtconfig).

## createRbacMiddleware

[Source](https://github.com/agentiumOS/agentium/blob/v4.0.0/packages/transport/src/express/rbac-middleware.ts)

```typescript theme={null}
export declare function createRbacMiddleware(config?: RbacConfig): (req: any, res: any, next: any) => any;
```

Related: [`RbacConfig`](/api-reference/transport/authentication#rbacconfig).

## JwtConfig

[Source](https://github.com/agentiumOS/agentium/blob/v4.0.0/packages/transport/src/express/jwt-middleware.ts)

```typescript theme={null}
export interface JwtConfig {
    secret: string;
    algorithm?: string;
    issuer?: string;
    audience?: string;
    extractFrom?: "header" | "cookie";
    cookieName?: string;
}
```

## RbacConfig

[Source](https://github.com/agentiumOS/agentium/blob/v4.0.0/packages/transport/src/express/rbac-middleware.ts)

```typescript theme={null}
export interface RbacConfig {
    scopeField?: string;
    /** Override an exact route pattern. Empty scopes explicitly permit authenticated access. */
    defaultScopes?: Record<string, string[]>;
    agentScopes?: Record<string, string[]>;
    /** Explicit routes accessible without authentication. Use only for intentionally public endpoints. */
    publicRoutes?: string[];
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.