The Change API enables you to manage your Changes and the Parameters within them.
Parameters are managed with JSON Patches RFC, and Changes are edited declaratively.
Accessible by clients or directly through HTTPS / GRPC, powered by Connect protocol.
import { createClient } from '@vect.io/api.connect.change.client.binding.web'
const client = createClient({ auth: '<access-key>' });
await client.changeAction({
patches: [{ path: 'example.json', operation: 'ADD', content: 'hello, world' }],
repository: { path: 'acme-com/acme-com-2024v1' },
});
More specific info is in each of the clients readme.
JavaScript / TypeScript
https://www.npmjs.com/package/@vect.io/api.connect.change.client.binding.web
https://www.npmjs.com/package/@vect.io/api.connect.change.client.binding.node
<aside> ❤️
We can generate new bindings very quickly. Just ask.
</aside>
Apply and name an existing Change
await client.changeAction({
uri: { cuid: 'cm3q42kb700003b6fmgto14ax' },
metadata: { name: 'example Change', toStatus: 'STATUS_APPLIED' },
repository: { path: 'acme-com/acme-com-2024v1' },
});
Open a Draft Change with parameters update through HTTPs
curl '<https://change.connect.api.vect.io/vect.change.v1.ChangeApiService/ChangeAction>' \\
-H "Authorization: Bearer <access-key>" -H "Content-type: application/json" \\
--data '{
"metadata": { "toStatus": "STATUS_DRAFT" },
"patches": [{ "path": "example.json", "operation": "ADD", "content": "hello, world" }],
"repository": { "path": "acme-com/acme-com-2024v1" }
}'