docs: v1.4 features (#7778)
* bump-supported-version-to-1.4.x * overview-page * small-naming-changes * change-folders-to-projects * api-examples-folder-to-projects * more * update-screenshots-and-text * sidebars * npx-astra-command * move-and-redirect-outdated-page * sidebars * tools-and-env-var * language * authentication * flow-description-and-tool * mcp-component-astra-db * rename-page * cleanup * update-message * update-for-client-strategy * sse-port-7868-and-api-key-creation * external-deploy * init-ngrok * add-ngrok-deploy * cleanup * cleanup * Minor capitalization fix * Fix message object anchors * Fix indentation of MCP server procedure * Add anchor link for MCP SSE mode * Mild cleanup of concepts overview * Fix indentation issues in mcp-component-astra * Use universal date format on luna-for-langflow * Update mcp-server doc * fix-missed-bracket * change-npx-to-uvx-mcp-proxy * update-screenshots-for-uvx * inspector-with-auth * Apply suggestions from code review Co-authored-by: Eric Schneider <37347760+eric-schneider@users.noreply.github.com> --------- Co-authored-by: Deon Sanchez <69873175+deon-sanchez@users.noreply.github.com> Co-authored-by: Eric Schneider <37347760+eric-schneider@users.noreply.github.com> Co-authored-by: Lucas Oliveira <lucas.edu.oli@hotmail.com>
This commit is contained in:
parent
710b6f99b5
commit
744df31f18
27 changed files with 516 additions and 308 deletions
|
|
@ -32,14 +32,14 @@ export FLOW_ID="359cd752-07ea-46f2-9d3b-a4407ef618da"
|
|||
```
|
||||
|
||||
- Export the `project-id` in your terminal.
|
||||
To find your project ID, call the Langflow [/api/v1/projects/](#read-projects) endpoint for a list of projects.
|
||||
|
||||
To find your project ID, call the Langflow [/api/v1/projects/](#read-projects) endpoint for a list of projects.
|
||||
<Tabs>
|
||||
|
||||
<TabItem value="curl" label="curl" default>
|
||||
|
||||
```bash
|
||||
curl -X GET \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
-H "accept: application/json"
|
||||
```
|
||||
|
|
@ -50,7 +50,7 @@ curl -X GET \
|
|||
[
|
||||
{
|
||||
"name": "My Projects",
|
||||
"description": "Manage your own flows. Download and upload projects.",
|
||||
"description": "Manage your own projects. Download and upload projects.",
|
||||
"id": "1415de42-8f01-4f36-bf34-539f23e47466",
|
||||
"parent_id": null
|
||||
}
|
||||
|
|
@ -59,8 +59,9 @@ curl -X GET \
|
|||
</TabItem>
|
||||
</Tabs>
|
||||
Export the `project-id` as an environment variable.
|
||||
Export the `project-id` as an environment variable.
|
||||
```bash
|
||||
export PROJECT_ID="1415de42-8f01-4f36-bf34-539f23e47466"
|
||||
export project_ID="1415de42-8f01-4f36-bf34-539f23e47466"
|
||||
```
|
||||
|
||||
- Export the Langflow API key as an environment variable.
|
||||
|
|
@ -1053,7 +1054,7 @@ To retrieve only the flows from a specific project, pass `project_id` in the que
|
|||
|
||||
```bash
|
||||
curl -X GET \
|
||||
"$LANGFLOW_URL/api/v1/flows/?remove_example_flows=true&components_only=false&get_all=false&project_id=$PROJECT_ID&header_flows=false&page=1&size=1" \
|
||||
"$LANGFLOW_URL/api/v1/flows/?remove_example_flows=true&components_only=false&get_all=false&project_id=$project_ID&header_flows=false&page=1&size=1" \
|
||||
-H "accept: application/json"
|
||||
```
|
||||
|
||||
|
|
@ -1122,6 +1123,7 @@ curl -X PATCH \
|
|||
"description": "string",
|
||||
"data": {},
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
||||
"endpoint_name": "my_new_endpoint_name",
|
||||
"locked": true
|
||||
}'
|
||||
|
|
@ -1147,6 +1149,7 @@ curl -X PATCH \
|
|||
"id": "01ce083d-748b-4b8d-97b6-33adbb6a528a",
|
||||
"user_id": "f58396d4-a387-4bb8-b749-f40825c3d9f3",
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
||||
}
|
||||
```
|
||||
|
||||
|
|
@ -1210,6 +1213,7 @@ curl -X POST \
|
|||
"locked": false,
|
||||
"user_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
||||
},
|
||||
{
|
||||
"name": "string",
|
||||
|
|
@ -1228,6 +1232,7 @@ curl -X POST \
|
|||
"locked": false,
|
||||
"user_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
||||
"project_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
||||
}
|
||||
]
|
||||
}'
|
||||
|
|
@ -1258,7 +1263,7 @@ This example uploads a local file named `agent-with-astra-db-tool.json`.
|
|||
|
||||
```bash
|
||||
curl -X POST \
|
||||
"$LANGFLOW_URL/api/v1/flows/upload/?project_id=$PROJECT_ID" \
|
||||
"$LANGFLOW_URL/api/v1/flows/upload/?project_id=$project_ID" \
|
||||
-H "accept: application/json" \
|
||||
-H "Content-Type: multipart/form-data" \
|
||||
-F "file=@agent-with-astra-db-tool.json;type=application/json"
|
||||
|
|
@ -1284,12 +1289,14 @@ curl -X POST \
|
|||
</TabItem>
|
||||
</Tabs>
|
||||
|
||||
To specify a target project for the flow, include the query parameter `project_id`.
|
||||
The target `project_id` must already exist before uploading a flow. Call the [/api/v1/projects/](#read-projects) endpoint for a list of available projects.
|
||||
To specify a target project for the flow, include the query parameter `project_id`.
|
||||
The target `project_id` must already exist before uploading a flow. Call the [/api/v1/projects/](#read-projects) endpoint for a list of available projects.
|
||||
|
||||
```bash
|
||||
curl -X POST \
|
||||
"$LANGFLOW_URL/api/v1/flows/upload/?project_id=$PROJECT_ID" \
|
||||
"$LANGFLOW_URL/api/v1/flows/upload/?project_id=$project_ID" \
|
||||
-H "accept: application/json" \
|
||||
-H "Content-Type: multipart/form-data" \
|
||||
-F "file=@agent-with-astra-db-tool.json;type=application/json"
|
||||
|
|
@ -1353,6 +1360,8 @@ A list of example flows.
|
|||
|
||||
## Projects
|
||||
|
||||
## Projects
|
||||
|
||||
Use the `/projects` endpoint to create, read, update, and delete projects.
|
||||
|
||||
Projects store your flows and components.
|
||||
|
|
@ -1366,6 +1375,7 @@ Get a list of Langflow projects.
|
|||
|
||||
```bash
|
||||
curl -X GET \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
-H "accept: application/json"
|
||||
```
|
||||
|
|
@ -1377,7 +1387,7 @@ curl -X GET \
|
|||
[
|
||||
{
|
||||
"name": "My Projects",
|
||||
"description": "Manage your own flows. Download and upload projects.",
|
||||
"description": "Manage your own projects. Download and upload projects.",
|
||||
"id": "1415de42-8f01-4f36-bf34-539f23e47466",
|
||||
"parent_id": null
|
||||
}
|
||||
|
|
@ -1389,6 +1399,9 @@ curl -X GET \
|
|||
|
||||
### Create project
|
||||
|
||||
### Create project
|
||||
|
||||
Create a new project.
|
||||
Create a new project.
|
||||
|
||||
<Tabs>
|
||||
|
|
@ -1396,11 +1409,13 @@ Create a new project.
|
|||
|
||||
```bash
|
||||
curl -X POST \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
-H "accept: application/json" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d '{
|
||||
"name": "new_project_name",
|
||||
"name": "new_project_name",
|
||||
"description": "string",
|
||||
"components_list": [],
|
||||
"flows_list": []
|
||||
|
|
@ -1412,6 +1427,7 @@ curl -X POST \
|
|||
|
||||
```json
|
||||
{
|
||||
"name": "new_project_name",
|
||||
"name": "new_project_name",
|
||||
"description": "string",
|
||||
"id": "b408ddb9-6266-4431-9be8-e04a62758331",
|
||||
|
|
@ -1422,17 +1438,21 @@ curl -X POST \
|
|||
</TabItem>
|
||||
</Tabs>
|
||||
|
||||
To add flows and components at project creation, retrieve the `components_list` and `flows_list` values from the [/api/v1/store/components](#get-all-components) and [/api/v1/flows/read](#read-flows) endpoints and add them to the request body.
|
||||
To add flows and components at project creation, retrieve the `components_list` and `flows_list` values from the [/api/v1/store/components](#get-all-components) and [/api/v1/flows/read](#read-flows) endpoints and add them to the request body.
|
||||
|
||||
Adding a flow to a project moves the flow from its previous location. The flow is not copied.
|
||||
Adding a flow to a project moves the flow from its previous location. The flow is not copied.
|
||||
|
||||
```bash
|
||||
curl -X POST \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
"$LANGFLOW_URL/api/v1/projects/" \
|
||||
-H "accept: application/json" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d '{
|
||||
"name": "new_project_name",
|
||||
"name": "new_project_name",
|
||||
"description": "string",
|
||||
"components_list": [
|
||||
"3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
||||
|
|
@ -1445,8 +1465,12 @@ curl -X POST \
|
|||
|
||||
### Read project
|
||||
|
||||
### Read project
|
||||
|
||||
Retrieve details of a specific project.
|
||||
Retrieve details of a specific project.
|
||||
|
||||
To find the UUID of your project, call the [read projects](#read-projects) endpoint.
|
||||
To find the UUID of your project, call the [read projects](#read-projects) endpoint.
|
||||
|
||||
<Tabs>
|
||||
|
|
@ -1454,7 +1478,7 @@ To find the UUID of your project, call the [read projects](#read-projects) endpo
|
|||
|
||||
```bash
|
||||
curl -X GET \
|
||||
"$LANGFLOW_URL/api/v1/projects/$PROJECT_ID" \
|
||||
"$LANGFLOW_URL/api/v1/projects/$project_ID" \
|
||||
-H "accept: application/json"
|
||||
```
|
||||
|
||||
|
|
@ -1464,8 +1488,8 @@ curl -X GET \
|
|||
```json
|
||||
[
|
||||
{
|
||||
"name": "My projects",
|
||||
"description": "Manage your own flows. Download and upload projects.",
|
||||
"name": "My Projects",
|
||||
"description": "Manage your own projects. Download and upload projects.",
|
||||
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
||||
"parent_id": null
|
||||
}
|
||||
|
|
@ -1477,8 +1501,12 @@ curl -X GET \
|
|||
|
||||
### Update project
|
||||
|
||||
### Update project
|
||||
|
||||
Update the information of a specific project with a `PATCH` request.
|
||||
Update the information of a specific project with a `PATCH` request.
|
||||
|
||||
Each PATCH request updates the project with the values you send.
|
||||
Each PATCH request updates the project with the values you send.
|
||||
Only the fields you include in your request are updated.
|
||||
If you send the same values multiple times, the update is still processed, even if the values are unchanged.
|
||||
|
|
@ -1488,6 +1516,7 @@ If you send the same values multiple times, the update is still processed, even
|
|||
|
||||
```bash
|
||||
curl -X PATCH \
|
||||
"$LANGFLOW_URL/api/v1/projects/b408ddb9-6266-4431-9be8-e04a62758331" \
|
||||
"$LANGFLOW_URL/api/v1/projects/b408ddb9-6266-4431-9be8-e04a62758331" \
|
||||
-H "accept: application/json" \
|
||||
-H "Content-Type: application/json" \
|
||||
|
|
@ -1521,6 +1550,9 @@ curl -X PATCH \
|
|||
|
||||
### Delete project
|
||||
|
||||
### Delete project
|
||||
|
||||
Delete a specific project.
|
||||
Delete a specific project.
|
||||
|
||||
<Tabs>
|
||||
|
|
@ -1528,7 +1560,7 @@ Delete a specific project.
|
|||
|
||||
```bash
|
||||
curl -X DELETE \
|
||||
"$LANGFLOW_URL/api/v1/projects/$PROJECT_ID" \
|
||||
"$LANGFLOW_URL/api/v1/projects/$project_ID" \
|
||||
-H "accept: */*"
|
||||
```
|
||||
|
||||
|
|
@ -1544,6 +1576,9 @@ curl -X DELETE \
|
|||
|
||||
### Download project
|
||||
|
||||
### Download project
|
||||
|
||||
Download all flows from a project as a zip file.
|
||||
Download all flows from a project as a zip file.
|
||||
|
||||
The `--output` flag is optional.
|
||||
|
|
@ -1553,9 +1588,11 @@ The `--output` flag is optional.
|
|||
|
||||
```bash
|
||||
curl -X GET \
|
||||
"$LANGFLOW_URL/api/v1/projects/download/b408ddb9-6266-4431-9be8-e04a62758331" \
|
||||
"$LANGFLOW_URL/api/v1/projects/download/b408ddb9-6266-4431-9be8-e04a62758331" \
|
||||
-H "accept: application/json" \
|
||||
--output langflow-project.zip
|
||||
--output langflow-project.zip
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
|
@ -1563,6 +1600,7 @@ curl -X GET \
|
|||
|
||||
```text
|
||||
The project contents.
|
||||
The project contents.
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
|
@ -1570,6 +1608,9 @@ The project contents.
|
|||
|
||||
### Upload project
|
||||
|
||||
### Upload project
|
||||
|
||||
Upload a project to Langflow.
|
||||
Upload a project to Langflow.
|
||||
|
||||
<Tabs>
|
||||
|
|
@ -1577,6 +1618,7 @@ Upload a project to Langflow.
|
|||
|
||||
```bash
|
||||
curl -X POST \
|
||||
"$LANGFLOW_URL/api/v1/projects/upload/" \
|
||||
"$LANGFLOW_URL/api/v1/projects/upload/" \
|
||||
-H "accept: application/json" \
|
||||
-H "Content-Type: multipart/form-data" \
|
||||
|
|
@ -1589,6 +1631,7 @@ curl -X POST \
|
|||
|
||||
```text
|
||||
The project contents are uploaded to Langflow.
|
||||
The project contents are uploaded to Langflow.
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue