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: server/mcp_server_tls/README.md
+111-7Lines changed: 111 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -350,6 +350,68 @@ Retrieve information for multiple topics under a specified project ID within the
350
350
351
351
Use the describe_topics_tool to find the shard count for the first 10 topics under the current project.
352
352
353
+
### Tool 7: put_logs_v2_tool
354
+
355
+
upload logs to the specified log topic.
356
+
357
+
- Required input parameters for debugging:
358
+
359
+
`Input`
360
+
361
+
```json
362
+
{
363
+
"inputSchema": {
364
+
"type": "object",
365
+
"required": ["logs"],
366
+
"properties": {
367
+
"logs": {
368
+
"type": "array",
369
+
"description": "logs field for the log field to be written, each item in the array is a log, each item consists of multiple key-value key-value pairs"
370
+
},
371
+
"log_time": {
372
+
"type": "int",
373
+
"description": "Log timestamp for writing to the log, default is current time",
374
+
},
375
+
"topic_id": {
376
+
"type": "string",
377
+
"description": "Optional log topic ID, default is the topic_id set in the environment variable, if not set, then must be passed."
378
+
},
379
+
"source": {
380
+
"type": "string",
381
+
"description": "The source of the logs, usually identified by the machine IP",
382
+
},
383
+
"filename": {
384
+
"type": "string",
385
+
"description": "Log file name",
386
+
},
387
+
"hash_key": {
388
+
"type": "string",
389
+
"description": "HashKey of the log group to specify the partition (Shard) to which the current log group is to be written",
390
+
},
391
+
"compression": {
392
+
"type": "string",
393
+
"description": "The compression format of the request body, default is lz4, optional zlib.",
394
+
},
395
+
}
396
+
},
397
+
"name": "put_logs_v2_tool",
398
+
"description": "Call the PutLogs interface to upload logs to the specified log topic. If you need to use searchLogs to query the logs, please set up the index first."
Use the put_logs_v2_tool tool to help me write the following logs as [{"user": "peter", "age": 18}, {"user": "marry", "age": 16}]
414
+
353
415
## Supported Platforms
354
416
355
417
Can be used with cline, cursor, Claude desktop, or other terminals supporting MCP server calls.
@@ -383,7 +445,7 @@ For server-based deployment, set `DEPLOY_MODE=remote` and only configure `REGION
383
445
384
446
### Run Locally
385
447
386
-
#### Option 1
448
+
#### 1. Launching via local code
387
449
388
450
```json
389
451
{
@@ -401,7 +463,7 @@ For server-based deployment, set `DEPLOY_MODE=remote` and only configure `REGION
401
463
}
402
464
```
403
465
404
-
#### Option 2
466
+
#### 2. Launch via remote repository
405
467
406
468
```json
407
469
{
@@ -427,25 +489,67 @@ For server-based deployment, set `DEPLOY_MODE=remote` and only configure `REGION
427
489
}
428
490
```
429
491
430
-
### Run Remote
492
+
### Remote startup
493
+
494
+
#### Deploying remote services
495
+
496
+
##### 1. Local direct startup
431
497
432
-
Set `DEPLOY_MODE=remote`.
498
+
Set `DEPLOY_MODE=remote`
433
499
434
500
```shell
435
501
uv --directory /ABSOLUTE/PATH/TO/PARENT/FOLDER run mcp-server-tls -t sse
436
502
```
437
503
438
-
When used by the caller, authentication information should be base64-encoded and included in the request header as `authorization`:
504
+
or
505
+
506
+
```shell
507
+
uv --directory /ABSOLUTE/PATH/TO/PARENT/FOLDER run mcp-server-tls -t streamable-http
508
+
```
509
+
510
+
> We suggest that using streamable-http
511
+
512
+
##### 2. Started by DOCKER
513
+
514
+
We also provide DOCKERFILE to facilitate your deployment, which has not been pushed to the open source repository, so you can manually package it first.
515
+
516
+
Example of docker compose startup.
517
+
518
+
```
519
+
services:
520
+
mcp:
521
+
image: your-image:your-version
522
+
container_name: mcp_server_tls
523
+
restart: always
524
+
ports:
525
+
- "80:8000"
526
+
environment:
527
+
MCP_DEPLOY_MODE: remote
528
+
TRANSPORT_TYPE: streamable-http
529
+
MCP_SERVER_HOST: 0.0.0.0
530
+
MCP_SERVER_PORT: 8000
531
+
```
532
+
533
+
#### call
534
+
535
+
|transport-type| call link example |
536
+
| :-: | :-: |
537
+
| sse |http://127.0.0.1:8000/sse|
538
+
| streamable-http |http://127.0.0.1:8000/mcp/|
539
+
540
+
The caller should put the authentication information in the authorization header after encoding it in base64 in the following format
439
541
440
542
```json
441
543
{
442
544
"AccessKeyId": "your ak",
443
545
"SecretAccessKey": "your sk",
444
-
"SessionToken": "your token"
546
+
"SessionToken": "your token",
547
+
"Region": "your region",
548
+
"Endpoint": "your endpoint"
445
549
}
446
550
```
447
551
448
-
## Configuration on Different Platforms
552
+
`Region` and `Endpoint` is not necessary, default region is `cn-beijing`, endpoint is `https://tls-cn-beijing.volces.com`
0 commit comments