Vizzlo Organizations & Teams
Retrieving organizations
Route
GET /api/v1/orgs/
org
Managing organization settings
Route
PATCH /api/v1/orgs/
org
This method can be used to update certain organization-specific settings. Currently, the following values can be updated using PATCH calls with query parameters:
default_theme: Specifies the default theme to use when a user that is members of this organization creates a new document. This setting shall be provided as string that identifies the theme—potentially including the organization’s id.
Example
curl -u USER:PASSWORD --request PATCH --data default_theme=abc123/orange https://vizzlo.com/api/v1/orgs/abc123
Managing organization user accounts
This section applies to organizations in the Enterprise plan, only!
About managed users
Enterprise organizations allow managing the user accounts for their employees ensuring that all users are administered from a central entity. This includes creating and deleting the accounts which can be done without the need to verify email addresses, etc.
A “managed user“ has the following restrictions compared to an individual user account:
- Managed users cannot create Vizzlo Professional subscriptions
- Managed users cannot be a member of multiple organizations
- Managed users need to have an email address that belongs to a verified domain name of the organization
- Managed users cannot change their email address using the self-service functionality
- Managed users cannot delete their account using the self-service functionality
Listing managed users
Route
GET /api/v1/orgs/
org/users
Query parameters
q(string): Optional: Only return members whose email address or name matches the given string.filter_role(string): Optional: Only return users that match the given role in the organization. Needs to be any ofadmin,brand_manager, ormember.offset(number): Optional: Offset of the first search result matching the query to return. (Default:0)limit(number): Optional: Maximum number of search results to return. This value cannot exceed100. (Default:100)
Return value
A JSON object with the following fields will be returned:
-
An object
org_subscriptionthat contains basic information about the subscription of the organization:name(string): Name of the subscription.current_member_count(number): Current number of seats taken.max_member_count(number): Maximum number of paid for seats.unlimited(boolean): Specifies if this subscriptions allows for an unlimited number of seats.free(boolean): Specifies if this organization is freely usable without a subscriptionperiod_interval(number): Payment period of the subscription.period(string): Payment period unit of the subscription.currency(string): Currency the subscription is paid for.price_per_period(number): Total price of the current subscription per period. Prices are always given in hundredths of the specified currency, ie. $12.50 are specified as1250with currencyUSD.price_per_user_and_period(number): Average price per seats for the user’s payment period.management_url(string): URL where the organization’s management settings interface is available for users.suspended(boolean): Specifies if this subscription is suspended due to a payment issue.
-
An array
usersthat contains a list of objects, each having the following set of fields:id(string): User ID of the given user.name(string): Full name of the user.email(string): Email address of the user.avatar_url(string): URL which can be used to show a profile picture of the user.role(string): Role of the user within the organization. Can be any ofadmin,brand_manager, ormember.last_seen(string): Timestamp of when the user was last active on Vizzlo as RFC 3339 encoded string.
If the request yields no results (ie. no user matches the specified
filter_roleorq), the fielduserswill be ommitted.
Paging headers
If more results for the given query are available, a pair of optional Link headers will be returned (with rel being prev or next) which can be used to page through the result set.
Getting information about a single managed user
Route
GET /api/v1/orgs/
org/users/id
Return value
A JSON object representing the user is returned that contains the following fields:
id(string): User ID of the given user.name(string): Full name of the user.email(string): Email address of the user.avatar_url(string): URL which can be used to show a profile picture of the user.role(string): Role of the user within the organization. Can be any ofadmin,brand_manager, ormember.last_seen(string): Timestamp of when the user was last active on Vizzlo as RFC 3339 encoded string.
Modifying managed users
Route
PATCH /api/v1/orgs/
org/users/id
Request payload
A JSON object containing one or more of the following fields should be sent to this endpoint:
email(string): New email address of the given user. The email address MUST be part of the verified domains of the organization for this request to succeed.name(string): New name of the given user.
Return value
Upon success, an empty result (HTTP status code 204) is returned.
Deleting managed users
Route
DELETE /api/v1/orgs/
org/users/id
Return value
Upon success, an empty result (HTTP status code 204) is returned.
Creating a new managed user
Creating new users in an organization is a two-stage process:
- The client sents a plan (“upgrade check”) to create a new managed user account for the organization. The server replies with the necessary details of the operation and—potentially—information about necessary subscription changes.
- The client confirms the operation.
In some cases (ie. customers who pay a flat fee regardless of the number of seats), the upgrade check might not be necessary, but will not hurt.
In all other cases, even if the current number of seats being paid for is sufficient, running an upgrade check is mandatory!
Part 1: Checking subscriptions status in preparation of creating a new user
Route
POST /api/v1/orgs/
org/users/check
Return value
A JSON object with the following fields will be returned:
update_needed(boolean): Is a subscription update necessary for this operation? Seeupdate_infobelow for more details about the necessary update.unlimited(boolean): The organization account is unlimited in the number of seats which can be used.new_member_count(number): Number of new members that would be created when confirming this operation.max_member_count(number): Current maximum number of seats this organization is configured for.subscription_revision(number): Numerical revision of the current set of members the organization has. This is to ensure that any confirmed subscription change transaction is really an atomic operation. To confirm this operation, you need to send this exact revision for the confirmation API call.
If an upgrade of the subscription is necessary, due to the current number of seats in the organization account not being sufficient, the response will contain another field, update_info, that contains the following information:
additional_seats(number): Number of additional seats which would be added to the account.total_seats(number): Total number of seats the subscription being used after the update.max_member_count(number): Maximum number of seats which can be used after the update.update_cost(number): Cost of the planned subscription update. This is the amount of the pro-rated invoice which will be generated.currency(string): Currency, the subscription update will be charged in.subscription_cost(number): New total subscription cost.billing_cycle_every(number): Interval of billing cycle which is used for the subscription.billing_cycle_unit(string): Unit of billing cycle which is used for the subscription.next_billing_at(string): Next time the subscription will be fully billed.subscription_status(string): Status the subscription will be in after the update.
Part 2: Confirming a potential subscription change to create a new user
Route
POST /api/v1/orgs/
org/users
Request payload
A JSON object with the following fields should be sent to this endpoint:
email(string): Email address of the given user. The email address MUST be part of the verified domains of the organization for this request to succeed.name(string): Name of the given user.role(string): Optional: Role of the user within the organization. Can be any ofadmin,brand_manager, ormember(default).teams(array of strings): Optional: List of team IDs to add this new user to right away.subscription_revision(number): Numerical revision which was returned to you as part of the request in part 1.
Return value
A JSON object that contains the following fields is returned:
user_id(string): User ID of the newly created user account.initial_password(string): The initial password of the newly created user account.
Inviting external users into the organization
If your organization is on an Enterprise plan, the possibility to invite external users might be disabled. In that case, all POST requests of this section will fail with HTTP Status 400.
Listing all open invites for an organization
Any organization member or open invitation will count towards the number of seats the organization is paying for.
Route
GET /api/v1/orgs/
org/invites
Return value
Upon success, a JSON object with one field invites (array of objects) is returned. Each object within this array contains these fields:
id(string): Identifier for this invitation.email(string): Email address of the person invited.invited_at(string): Timestamp (ISO 8601 encoded) of when the person was invited.sent_at(string): Timestamp (ISO 8601 encoded) of when the invitation was last (re-)sent.inviter_username(string): User ID of the person who triggered this invitation.inviter_name(string): Full name of the person who triggered this invitation.inviter_avatar_url(string): URL of the avatar image of the person who triggered this invitation.
Inviting external users to an organization
Inviting new members to an organization is a two-stage process:
- The client sents a plan (“invite check”) to invite a given list of addresses to the organization. The server replies with the necessary details of the operation and—potentially—information about necessary subscription changes.
- The client confirms the operation.
Part 1: Checking subscriptions status in preparation of sending out invitations
Route
POST /api/v1/orgs/
org/invites/check
Request payload
A JSON object containing the following fields should be sent to this endpoint:
emails(array of strings): List of the email addresses that you want to invite as members of the organization.
Return value
A JSON object with the following fields will be returned:
update_needed(boolean): Is a subscription update necessary for this operation? Seeupdate_infobelow for more details about the necessary update.unlimited(boolean): The organization account is unlimited in the number of seats which can be used.new_member_count(number): Number of new members that will be invited when confirming this operation.max_member_count(number): Current maximum number of seats this organization is configured for.addresses_to_really_add(array of strings): List of email addresses which will be added if confirming the operation. Already existing members or invites will be filtered from this list.subscription_revision(number): Numerical revision of the current set of members the organization has. This is to ensure that any confirmed subscription change transaction is really an atomic operation. To confirm this operation, you need to send this exact revision for the confirmation API call.
If an upgrade of the subscription is necessary, due to the current number of seats in the organization account not being sufficient for the number of requested invites, the response will contain another field, update_info, that contains the following information:
additional_seats(number): Number of additional seats which would be added to the account.total_seats(number): Total number of seats the subscription being used after the update.max_member_count(number): Maximum number of seats which can be used after the update.update_cost(number): Cost of the planned subscription update. This is the amount of the pro-rated invoice which will be generated.currency(string): Currency, the subscription update will be charged in.subscription_cost(number): New total subscription cost.billing_cycle_every(number): Interval of billing cycle which is used for the subscription.billing_cycle_unit(string): Unit of billing cycle which is used for the subscription.next_billing_at(string): Next time the subscription will be fully billed.subscription_status(string): Status the subscription will be in after the update.
Part 2: Confirming a subscription change to send out invitations
Route
POST /api/v1/orgs/
org/invites
Request payload
A JSON object containing the following fields should be sent to this endpoint:
emails(array of strings): List of the email addresses that you want to invite as members of the organization.subscription_revision(number): Numerical revision which was returned to you as part of the request in part 1.
Return value
Upon success, an empty result is returned.
Deleting an open invite
Route
DELETE /api/v1/orgs/
org/invite/id
Re-sending an open invitation
Route
POST /api/v1/orgs/
org/invites/id/send
Managing organization members
Listing members of an organization
Route
GET /api/v1/orgs/
org/members
Query parameters
filter_role(string): Optional: Only return members that match the given role. Needs to be any ofadmin,brand_manager, ormember.q(string): Optional: Only return members whose email address or name matches the given string.limit(number): Optional: Maximum number of search results to return. This value cannot exceed100. (Default:100)offset(number): Optional: Offset of the first search result matching the query to return. (Default:0)
Return value
A JSON object with the following fields will be returned:
-
An object
org_subscriptionthat contains basic information about the subscription of the organization:name(string): Name of the subscription.current_member_count(number): Current number of seats taken.max_member_count(number): Maximum number of paid for seats.unlimited(boolean): Specifies if this subscriptions allows for an unlimited number of seats.free(boolean): Specifies if this organization is freely usable without a subscriptionperiod_interval(number): Payment period of the subscription.period(string): Payment period unit of the subscription.currency(string): Currency the subscription is paid for.price_per_period(number): Total price of the current subscription per period. Prices are always given in hundredths of the specified currency, ie. $12.50 are specified as1250with currencyUSD.price_per_user_and_period(number): Average price per seats for the user’s payment period.management_url(string): URL where the organization’s management settings interface is available for users.suspended(boolean): Specifies if this subscription is suspended due to a payment issue.
-
An array
membersthat contains a list of objects, each having the following set of fields:id(string): User ID of the given organization member.name(string): Full name of the user.email(string): Email address of the user.avatar_url(string): URL which can be used to show a profile picture of the user.role(string): Role of the user within the organization. Can be any ofadmin,brand_manager, ormember.last_seen(string): Timestamp of when the user was last active on Vizzlo as RFC 3339 encoded string.managed(boolean):truefor managed user accounts,falsefor individual accounts.
If the request yields no results (ie. no member matches the specified
filter_roleorq), the fieldmemberswill be ommitted.
Paging headers
If more results for the given query are available, the a pair of optional Link headers will be returned (with rel being prev or next) which can be used to page through the result set.
Removing members from an organization
Route
POST /api/v1/orgs/
org/members/remove
Query parameters
id(string): User ID of the member to remove from the organization.
Managing organization themes
Routes
- GET /api/v1/orgs/
org/themes - GET /api/v1/orgs/
org/themes/theme - PUT /api/v1/orgs/
org/themes/theme - DELETE /api/v1/orgs/
org/themes/theme
Managing organization assets
Listing assets
Route
GET /api/v1/orgs/
org/assets
Example
curl -u USER:PASSWORD https://vizzlo.com/api/v1/orgs/abc123/assets
Add or updating organization assets
Routes
- PUT /api/v1/orgs/
org/assets/filename - POST /api/v1/orgs/
org/assets
Deleting assets
DELETE /api/v1/orgs/
org/assets/filename
Example
curl -u USER:PASSWORD -X DELETE https://vizzlo.com/api/v1/orgs/abc123/assets/FILENAME
Managing Teams
Listing all teams of an organization
Route
GET /api/v1/orgs/
org/teams
Creating a new team
Route
POST /api/v1/orgs/
org/teams
Getting information about a specific team
Route
GET /api/v1/orgs/
org/team/team
Adding/Removing members of a team
id is the user ID of the member to add to or remove from the team.
Routes
PUT /api/v1/orgs/
org/team/team/member/id
DELETE /api/v1/orgs/
org/team/team/member/id
Updating information of a specific team
Route
PUT /api/v1/orgs/
org/team/team
Deleting a team
Route
DELETE /api/v1/orgs/
org/team/team
Verified domains
This section applies to organizations on an Enterprise or Education plan, only. All of these calls require the caller to be an admin of the organization.
Verified domains are the internet domains an organization owns. They are a prerequisite for managing user accounts (managed users must have an email address on a verified domain) and for SAML/SSO just-in-time provisioning.
A domain is verified by publishing a DNS TXT record. Registering a domain returns a record_value that you publish as a TXT record on the domain (the record name is the domain itself). Once published, trigger verification, which performs a live DNS lookup.
Every domain object returned by these endpoints has the following shape:
| Name | Type | Description |
|---|---|---|
domain | string | The domain name. |
status | string | Verification status: pending, verified, or failed. |
record_value | string | The value to publish as a DNS TXT record, e.g. vizzlo-domain-verification=…. |
last_checked | string | Optional: Timestamp (RFC 3339) of the last verification attempt. |
verified_at | string | Optional: Timestamp (RFC 3339) of when the domain was verified. |
Listing verified domains
Route
GET /api/v1/orgs/
org/domains
Return value
A JSON object with a single field verifications (array of objects), each having the shape described above.
Registering a new domain
Route
POST /api/v1/orgs/
org/domains
Request payload
{
"domain": "example.com"
}
The domain must be a valid domain name and must not be a public/free email provider domain. It also must not already be verified by another organization.
Return value
A single domain object with status set to pending. Publish its record_value as a DNS TXT record on the domain before verifying.
Verifying a domain
Performs a live DNS TXT lookup for the domain and marks it verified if a record matching the domain’s record_value is found, or failed otherwise.
Route
POST /api/v1/orgs/
org/domains/domain/verify
Return value
The updated domain object (with status of verified or failed).
Removing a domain
Route
DELETE /api/v1/orgs/
org/domains/domain
Return value
No content (HTTP status code 204) upon success.
Organization settings
Beyond the single-value settings that can be changed via PATCH on the organization itself, organizations have a structured settings object that controls policies and layout presets.
Reading the settings is allowed for any member; changing them requires the brand_manager or admin role.
The settings object has the following fields:
| Name | Type | Description |
|---|---|---|
layouts | array | Layout presets (see below). |
auto_invite_domain_users | boolean | Automatically invite users signing up with a verified-domain email address. |
auto_update_seat_count | boolean | Automatically grow the subscription’s seat count when needed. |
auto_update_seat_count_limit | number | Optional: Upper bound for automatic seat-count growth. |
enforce_sso | boolean | Require members to sign in via SSO. |
disable_unmanaged_accounts | boolean | Disallow individual (unmanaged) accounts for members. |
disable_document_storage | boolean | Disable cloud document storage for members (offline use only). |
disable_public_documents | boolean | Force all documents of the organization to be private. |
Each entry in layouts is an object with name (string), width (number, pt), height (number, pt), display_unit (string), and margin (object with top, right, bottom, left in pt).
Reading the settings object
Route
GET /api/v1/orgs/
org/settings
Return value
The full settings object as described above.
Replacing the settings object
Replaces the whole settings object with the request payload.
Route
PUT /api/v1/orgs/
org/settings
Return value
No content (HTTP status code 204) upon success.
Updating individual settings
Sends a partial settings object; only the keys present are updated.
Route
PATCH /api/v1/orgs/
org/settings
Request payload
{
"enforce_sso": true
}
Unknown keys result in HTTP status code 400.
Return value
No content (HTTP status code 204) upon success.
Appending a layout preset
Appends a single layout preset to the layouts list.
Route
POST /api/v1/orgs/
org/settings/layouts
Request payload
{
"name": "Widescreen",
"width": 960,
"height": 540,
"display_unit": "pt",
"margin": { "top": 40, "right": 40, "bottom": 40, "left": 40 }
}
Return value
No content (HTTP status code 204) upon success.
Deleting a setting or layout preset
DELETE /api/v1/orgs/org/settings/key“ resets the single settingkey(e.g.enforce_sso) to its default value.DELETE /api/v1/orgs/org/settings/layouts/name“ removes the layout preset with the givenname.
Return value
No content (HTTP status code 204) upon success.
Subscription information
Returns a summary of the organization’s subscription. Requires the admin role.
Route
GET /api/v1/orgs/
org/subscription
Return value
A JSON object describing the subscription. It contains the same basic fields as the org_subscription object embedded in the member and managed-user listings (name, current_member_count, max_member_count, unlimited, free, period, period_interval, currency, price_per_period, price_per_user_and_period, management_url, suspended), plus additional fields such as:
status(string): Current status of the subscription.features(object): Feature flags of the subscription, e.g.managed_accounts(boolean).next_billing_at(string): Timestamp (RFC 3339) of the next billing.cancelled_at(string): Timestamp (RFC 3339) of when the subscription was cancelled, if applicable.has_scheduled_changes(boolean): Whether scheduled changes exist for this subscription.scheduled_price_per_period,scheduled_seat_count,scheduled_period,scheduled_period_interval: Details of any scheduled change.updated_at(string): Timestamp (RFC 3339) of when this information was last synced.
If the organization has no billing subscription, an empty result (HTTP status code 204) is returned.
Audit log
Returns the organization’s audit-log events from the last 90 days. Requires the admin role on an Enterprise-plan organization (or operator access).
Route
GET /api/v1/orgs/
org/audit-log
Query parameters
offset(number): Optional: Skips this number of results. (Default:0)limit(number): Optional: Limits the number of results. (Default:100)
Return value
A JSON object with the following fields:
limit(number): The limit used for this request.offset(number): The offset used for this request.count(number): Total number of events available in the 90-day window.events(array of objects): The events, each having these fields:timestamp(string): Timestamp (RFC 3339) of the event.event_category(string): Category of the event.event_name(string): Name of the event.document_id(string): Document the event relates to, if any.event_properties(object): Event-specific properties.request_properties(object): Properties of the request that triggered the event.source(string): Source of the event.user(object): The acting user, withid,name,email, andavatar_url.