curl --request POST \
--url https://memex.garden/api/ensure-shared-library-entry-link \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"contentId": "content_entity_id",
"accessMode": "public_link"
}
'{
"sharedResourceId": "<string>",
"accessMode": "public_link",
"contentId": "<string>",
"contentType": "web",
"createdAt": "2023-11-07T05:31:56Z",
"publicToken": "<string>",
"title": "<string>",
"description": "<string>"
}{
"error": "Unauthorized"
}{
"error": "Internal server error",
"message": "<string>"
}API reference
Create a public sharing link
Creates or returns a public share link for a saved content entity owned by the authenticated user. Use public_link for view access and public_link_contribute for collaborative access.
POST
/
ensure-shared-library-entry-link
curl --request POST \
--url https://memex.garden/api/ensure-shared-library-entry-link \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"contentId": "content_entity_id",
"accessMode": "public_link"
}
'{
"sharedResourceId": "<string>",
"accessMode": "public_link",
"contentId": "<string>",
"contentType": "web",
"createdAt": "2023-11-07T05:31:56Z",
"publicToken": "<string>",
"title": "<string>",
"description": "<string>"
}{
"error": "Unauthorized"
}{
"error": "Internal server error",
"message": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Saved content entity ID to share.
public_link grants view access. public_link_contribute grants collaborative access.
Available options:
public_link, public_link_contribute Optional unsaved content payload. If the content ID is not already saved, Memex can save this entity before creating the share link.
Show child attributes
Show child attributes
Response
Public sharing link
public_link grants view access. public_link_contribute grants collaborative access.
Available options:
public_link, public_link_contribute Exact persisted content_entity.type value.
Available options:
web, pdf, youtube, twitter, instagram, tiktok, facebook, linkedin, pinterest, reddit, chatgpt, claude, annotation, image, transcribedMedia, audioRecording, selector, chatThread, twitterProfile, subreddit, youtubeChannel 
