HTTP

Versia uses the HTTP protocol for all communications between instances. HTTP requests must conform to certain standards to ensure compatibility between different implementations, as well as to ensure the security and integrity of the data being exchanged.

ALL kinds of HTTP requests/responses between instances MUST include a Signature, signed with either the relevant User's private key or the instance's private key.

Requests

  • Name
    Accept
    Required
    Required
    Type
    string
    Description

    Must include application/json.

  • Name
    Content-Type
    Required
    Required
    Type
    string
    Description

    Must include application/json; charset=utf-8, if the request has a body.

  • Name
    Versia-Signature
    Type
    string
    Description

    See Signatures for more information.

  • Name
    Versia-Signed-By
    Type
    URI
    Description

    See Signatures.

  • Name
    Versia-Signed-At
    Type
    string
    Description

    See Signatures.

  • Name
    User-Agent
    Type
    string
    Description

    A string identifying the software making the request.

Example Request

POST https://bob.com/users/1/inbox HTTP/1.1
Accept: application/json
User-Agent: CoolServer/1.0 (https://coolserver.com)
Versia-Signature: /CjB2L9bcvRg+uP19B4/rqy7Ji9/cqMFPlL3GVCIndnQjYyOpBzJEAl9weDnXm7Jrqa3y6sBC+EYWKThO2r9Bw==
Versia-Signed-By: https://example.com/users/1
Versia-Signed-At: 1729241687

Rate limits

Implementations MUST respect the rate limits of remote instances.

IETF draft draft-polli-ratelimit-headers-02 MUST be used to communicate rate limits. Other rate limit headers/formats are not allowed.

Responses

  • Name
    Content-Type
    Required
    Required
    Type
    string
    Description

    Must include application/json; charset=utf-8.

  • Name
    Versia-Signature
    Type
    string
    Description

    See Signatures for more information.

  • Name
    Versia-Signed-By
    Type
    URI
    Description

    See Signatures.

  • Name
    Versia-Signed-At
    Type
    string
    Description

    See Signatures.

Example Response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Versia-Signature: /CjB2L9bcvRg+uP19B4/rqy7Ji9/cqMFPlL3GVCIndnQjYyOpBzJEAl9weDnXm7Jrqa3y6sBC+EYWKThO2r9Bw==+7BvnWKITyGyTwHbb6fVYwRx1I
Versia-Signed-By: https://example.com/users/1
Versia-Signed-At: 1729241717