Save material: Save material to the Material Library.
Debug
You can run this API directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After a successful run, OpenAPI Explorer can automatically generate SDK code examples.
Debug
RAM authorization
The following table describes the authorization information for this API. You can use the Action element in RAM permission policy statements to grant RAM users or RAM roles the permission to call this API. Details are as follows:
- Operation: the specific permission point.
- Access level: the access level of each operation. Valid values: Write, Read, or List.
-
Resource type: the resource types that support authorization for the operation. Details are as follows:
- Required resource types are marked with a preceding asterisk (*).
- For operations that do not support resource-level authorization,
All resourcesis used.
- Condition key: the condition keys defined by the cloud service itself.
- Dependent action: the other permissions required to successfully perform the operation. The caller must have the permissions of all dependent actions for the operation to succeed.
| Operation | Access level | Resource type | Condition key | Dependent action |
|---|---|---|---|---|
| aimiaobi:SaveMaterialDocument | create | *All resources * |
| None |
Request parameters
| Name | Type | Required | Description | Example |
|---|---|---|---|---|
| AgentKey | string | Yes | Unique identifier of the workspace: AgentKey | c160c841c8e54295bf2f441432785944_p_efm |
| DocType | string | Yes | Document type (html: web page, plainText: plain text, image: image, pdf: pdf, word: word, excel: excel, csv: csv, jsonLine: jsonLine) | excel |
| Title | string | No | Document title | News title |
| Author | string | No | Author | Author name |
| PubTime | string | No | Publication time, format: yyyy-MM-dd HH:mm:ss | 2023-04-11 06:14:07 |
| DocKeywords | array | No | Document tags used for classification, etc. | |
| DocKeyword | string | No | Keyword | Keyword |
| Url | string | No | URL of the material | http://xxxxx/xxx |
| ExternalUrl | string | No | URL uploaded by external customers, used only for record keeping | http://xxxxx/xxx |
| SrcFrom | string | No | Document source (UserUpload: User Upload, IntellijSearch: Intelligent Search, HotViewPoint: Hot Viewpoint) | IntellijSearch |
| TextContent | string | No | Parsed text content, empty for images | Text content |
| HtmlContent | string | No | Formatted content | Web page content |
| ShareAttr | integer | No | Sharing attribute: 0: private, 1: shared within the workspace | 1 |
| BothSavePrivateAndShare | boolean | No | Whether to save the material to both the private library and the shared library | false |
| Summary | string | No | Summary | Summary |
Response parameters
| Name | Type | Description | Example |
|---|---|---|---|
| object | PlainResult | ||
| Code | string | Status code | DataNotExists |
| Data | long | Business data | 12 |
| HttpStatusCode | integer | HTTP status code | 200 |
| Message | string | Error description | Data does not exist |
| RequestId | string | Unique request identifier | 3f7045e099474ba28ceca1b4eb6d6e21 |
| Success | boolean | Whether the request is successful: true for success, false for failure | false |
Examples
Normal response example
JSON format