Skip to content

Share an existing share with a teammate by email.

POST
/v1/shares/{id}/share-with
curl --request POST \
--url https://api.share2.us/v1/shares/example/share-with \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "email": "hello@example.com", "visibility": "private" }'

Sends the existing share to a teammate. public emails the public link without changing recipient restrictions. private marks the share as recipient-restricted and adds the teammate as an allowed recipient.

id
required
string
Media typeapplication/json
object
email
required
string format: email
visibility
required
string
Allowed values: private public

Updated share metadata.

Media typeapplication/json
object
id
required
string
public_id
required
string
>= 12 characters
url
required
string format: uri
filename
required
string
size_bytes
required
integer format: int64
content_class
string
Allowed values: text image document archive binary
state
required
string
Allowed values: created uploading uploaded scanning ready expired revoked blocked deleted
download_count
integer
max_downloads
integer
>= 1
password_protected
boolean
recipient_restricted

What the share ACTUALLY is. On the create response this is what lets a client that asked for visibility: private tell it got one: an older server ignores the field and returns a 201 with a PUBLIC link, so an ABSENT value must be read as “unknown”, never as false.

boolean
encrypted
boolean
scan_status

Malware scan outcome. skipped means the file was not scanned (scanning off, encrypted, or scanner unavailable) and is served with a visible warning; only a real dirty verdict blocks a share (ADR-013).

string
Allowed values: pending clean blocked skipped
expires_at
required
string format: date-time
created_at
required
string format: date-time
Example
{
"content_class": "text",
"state": "created",
"scan_status": "pending"
}

Invalid email or visibility.

Share not found for this account.

Standard error envelope.

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
request_id
required
string
Example
{
"error": {
"code": "quota_exceeded"
}
}