com.atproto.repo.putRecord
POST/xrpc/com.atproto.repo.putRecord
This endpoint is part of the atproto PDS repository management APIs. Requests usually require authentication (unlike the com.atproto.sync.*
endpoints), and are made directly to the user's own PDS instance.
To learn more about calling atproto API endpoints like this one, see the API Hosts and Auth guide.
Write a repository record, creating or updating it as needed. Requires auth, implemented by PDS.
Request
- application/json
Body
required
The handle or DID of the repo (aka, current account).
The NSID of the record collection.
Possible values: <= 15 characters
The Record Key.
Can be set to 'false' to skip Lexicon schema validation of record data, 'true' to require it, or leave unset to validate only for known Lexicons.
Compare and swap with the previous record by CID. WARNING: nullable and optional field; may cause problems with golang implementation
Compare and swap with the previous commit by CID.
Responses
- 200
- 400
- 401
OK
- application/json
- Schema
- Example (from schema)
Schema
commit
object
Possible values: [valid
, unknown
]
{
"uri": "string",
"cid": "string",
"commit": {
"cid": "string",
"rev": "string"
},
"validationStatus": "valid"
}
Bad Request
- application/json
- Schema
- Example (from schema)
Schema
Possible values: [InvalidRequest
, ExpiredToken
, InvalidToken
, InvalidSwap
]
{
"error": "InvalidRequest",
"message": "string"
}
Unauthorized
- application/json
- Schema
- Example (from schema)
Schema
{
"message": "string"
}