SDK reference

Passwords vault

Each route's function in the SDK, its call beside the same request in cURL.
meVault

GET/v1/me/vault

Your Passwords vault as stored: account (the keyset sealed under your master password and Secret Key, the Argon2id settings and salt, the public keys) or null, vaults with their wrapped keys and counters, devices, a pending reset and limits. Everything that says what's in the vault is encrypted on your devices. From the Authenticator app's sign-in only.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/vault' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeVault

POST/v1/me/vault

Makes your vault: the account, a personal vault and the first device, all sealed on the device and signed with the new vault's own key (X-Vault-Signature). 409 (exists) when you have one, unless its reset is due, when the old vault is deleted first.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/vault' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "accountId": "<accountId>",
    "kdf": {
      "alg": "argon2id",
      "m": 1,
      "t": 1,
      "p": 1
    },
    "kdfSalt": "example",
    "keyset": {},
    "encryptionPublicKey": "example",
    "signingPublicKey": "example",
    "vault": {
      "vaultId": "<vaultId>",
      "envelope": {},
      "attrs": {}
    },
    "device": {
      "deviceId": "<deviceId>",
      "name": "Example",
      "platform": "ios"
    }
  }'
putMeVaultKeyset

PUT/v1/me/vault/keyset

Replaces the sealed keyset after a new master password or Secret Key, if keysetRevision is still current (409 otherwise). Signed by the vault. Emails you.

Parameters and answers
curl -X PUT 'https://api.cactive.com.au/v1/me/vault/keyset' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "kdf": {
      "alg": "argon2id",
      "m": 1,
      "t": 1,
      "p": 1
    },
    "kdfSalt": "example",
    "keyset": {},
    "keysetRevision": 1
  }'
deleteMeVault

DELETE/v1/me/vault

Signed by the vault: deletes it now (items, vaults, devices and keys; the log stays). Without a signature (you can't open it any more): asks for a reset (202, reset), which may happen 7 days later unless a device that can open the vault cancels it. Emails you either way.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/vault' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeVaultResetCancel

POST/v1/me/vault/reset/cancel

Cancels a pending reset. Signed by the vault.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/vault/reset/cancel' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meVaultVaultsIndex

GET/v1/me/vault/vaults/:vaultId/index

The vault's counter (revision) and every item's itemId, revision and whether it was deleted, without ciphertext: devices compare it with their copy.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/vault/vaults/{vaultId}/index' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meVaultVaultsItems

GET/v1/me/vault/vaults/:vaultId/items

Up to 100 items by id (ids, comma-separated): each item's sealed key, overview and details (absent for deleted ones), revision and times.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/vault/vaults/{vaultId}/items' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeVaultVaultsItems

POST/v1/me/vault/vaults/:vaultId/items

Writes up to 50 changes (a sealed key, overview and details, or deleted: true), each only if the item is still at its baseRevision (0: new; deletes go first). Per change: ok with the new revision, conflict with the item as it is now, or rejected (limit: the plan's item limit). Signed by the vault.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/vault/vaults/{vaultId}/items' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "changes": [
      {
        "itemId": "<itemId>",
        "baseRevision": 1
      }
    ]
  }'
putMeVaultDevicesByDeviceId

PUT/v1/me/vault/devices/:deviceId

Registers this device (name, platform: ios, android or web) or renames it; signed by the vault with the device's own id. Up to 20 devices; a removed id can't come back. Emails you about a new device.

Parameters and answers
curl -X PUT 'https://api.cactive.com.au/v1/me/vault/devices/{deviceId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example",
    "platform": "ios"
  }'
deleteMeVaultDevicesByDeviceId

DELETE/v1/me/vault/devices/:deviceId

Removes a device; it stops syncing and wipes its copy when it next connects. Signed by the vault.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/vault/devices/{deviceId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meVaultActivity

GET/v1/me/vault/activity

Your vault's log, newest first, kept a year: made, devices added and removed, master password or Secret Key changes, resets, deletion, and counts of changed items. Never contents.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/vault/activity' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"