θΏ™ζ˜―indexlocζδΎ›ηš„ζœεŠ‘οΌŒδΈθ¦θΎ“ε…₯任何密码
Skip to content

Conversation

@yond1994
Copy link
Contributor

Pull Request Type

  • ✨ feat
  • πŸ› fix
  • ♻️ refactor
  • πŸ’„ style
  • πŸ”¨ chore
  • πŸ“ docs

Relevant Issues

resolves #1051

What is in this change?

This pull request introduces a new API endpoint to update the pin status of a document within a workspace.

Key Changes:

  1. New Endpoint:

    • Path: /workspace/:slug/update-pin
    • Method: POST
    • Description: Allows users to add or remove the pin status of a specified document in a workspace.
  2. Endpoint Details:

    • Parameters:
      • slug: Unique identifier of the workspace (in path).
      • Authorization: Token (in header).
    • Request Body:
      {
        "docPath": "custom-documents/my-pdf.pdf-hash.json",
        "pinStatus": true
      }
    • Responses:
      • 200 OK: Pin status updated successfully.
      • 404 Not Found: Document not found.
      • 500 Internal Server Error: Internal server error.
  3. Documentation:

    • Added the new endpoint to openapi.json for easy reference in Swagger UI at http://localhost:3001/api-docs.

    These changes enhance document management by allowing users to efficiently update pin statuses via the API.


Developer Validations

  • I ran yarn lint from the root of the repo & committed changes
  • Relevant documentation has been updated
  • I have tested my code functionality
  • Docker build succeeds locally

@timothycarambat timothycarambat added the PR:needs review Needs review by core team label May 19, 2024
@timothycarambat timothycarambat self-assigned this May 19, 2024
@timothycarambat timothycarambat merged commit ecd5d3c into Mintplex-Labs:master May 19, 2024
@timothycarambat
Copy link
Member

@yond1994 LMK what your discord handle is or ping me in Discord directly if you are in there and I can give the contributor badge in there as wel

@yond1994
Copy link
Contributor Author

yond1994 commented May 19, 2024

@timothycarambat Thank you very much, if I am in the discord my user is heavydeveloper

CrackerCat pushed a commit to CrackerCat/anything-llm that referenced this pull request Jul 31, 2024
CrackerCat pushed a commit to CrackerCat/anything-llm that referenced this pull request Aug 1, 2024
CrackerCat pushed a commit to CrackerCat/anything-llm that referenced this pull request Aug 2, 2024
CrackerCat pushed a commit to CrackerCat/anything-llm that referenced this pull request Aug 3, 2024
cabwds pushed a commit to cabwds/anything-llm that referenced this pull request Jul 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR:needs review Needs review by core team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT]: API - Document pinning support

2 participants