You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: en/includes/quick-starts/agent-auth-ts.md
-20Lines changed: 0 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -114,26 +114,6 @@ Pick your agent development framework and install the corresponding dependencies
114
114
npm install @ai-sdk/google @asgardeo/javascript @modelcontextprotocol/sdk ai base64url dotenv fast-sha256 jose secure-random-bytes typescript
115
115
npm install --save-dev @types/node
116
116
```
117
-
Initialize the TypeScript configuration by running the following command.
118
-
119
-
```bash
120
-
npx tsc --init
121
-
```
122
-
123
-
Update the `tsconfig.json` file with the following settings.
124
-
125
-
```json title="tsconfig.json"
126
-
{
127
-
"compilerOptions": {
128
-
"target": "ES2020",
129
-
"module": "commonjs",
130
-
"strict": true,
131
-
"esModuleInterop": true,
132
-
"skipLibCheck": true,
133
-
"forceConsistentCasingInFileNames": true
134
-
}
135
-
}
136
-
```
137
117
138
118
Create `agent.ts` that implements an AI agent which first obtains a valid access token from **{{ product_name }}** by authenticating itself. The agent then includes that token in the `Authorization` header (for example `Authorization: Bearer <token>`) when calling the MCP tool.
0 commit comments