SaltStack SharePoint

SaltStack SharePoint

/api/sharepoint-users/

A filter backend that uses django-filter. Supported actions and methods:

/api/sharepoint-users/

Methods: GET, POST

Supported fields for creation:

  • tenantlink to /api/sharepoint-tenants/<uuid>/
  • namestring
  • emailemail
  • first_namestring
  • last_namestring
  • usernamestring
  • phone – string
  • notify – boolean

Filter fields:

  • ?username = string
  • ?first_name = string
  • ?last_name = string
  • ?name = string
  • ?email = string
  • ?tenant_uuid = UUIDFilter
  • ?tenant = link

Order fields: email, first_name, last_name, name, username

/api/sharepoint-users/<uuid>/

Methods: GET, PUT, PATCH, DELETE

Supported fields for update:

  • namestring
  • emailemail
  • first_namestring
  • last_namestring
  • usernamestring
  • phone – string

/api/sharepoint-users/<uuid>/password/

Methods: POST, PUT

/api/sharepoint-tenants/

SLA filter

Allows to filter or sort resources by actual_sla Default period is current year and month.

Example query parameters for filtering list of OpenStack instances:

/api/openstack-instances/?actual_sla=90&period=2016-02

Example query parameters for sorting list of OpenStack instances:

/api/openstack-instances/?o=actual_sla&period=2016-02

Monitoring filter

Filter and order resources by monitoring item. For example, given query dictionary

{
    'monitoring__installation_state': True
}

it produces following query

{
    'monitoring_item__name': 'installation_state',
    'monitoring_item__value': True
}

Example query parameters for sorting list of OpenStack instances:

/api/openstack-instances/?o=monitoring__installation_state

Tags ordering. Filtering for complex tags.

Example:
?tag__license-os=centos7 - will filter objects with tag “license-os:centos7”.
Allow to define next parameters in view:
  • tags_filter_db_field - name of tags field in database. Default: tags.
  • tags_filter_request_field - name of tags in request. Default: tag.

In PostgreSQL NULL values come last with ascending sort order. In MySQL NULL values come first with ascending sort order. This filter provides unified sorting for both databases. Supported actions and methods:

/api/sharepoint-tenants/

Methods: GET, POST

Supported fields for creation:

  • namestring
  • description – string
  • service_project_linklink to /api/saltstack-service-project-link/<pk>/
  • domainstring
  • storageinteger
  • site_namestring (Main site collection name.)
  • site_descriptionstring (Main site collection description.)
  • templatelink to /api/sharepoint-templates/<uuid>/
  • phone – string
  • notify – boolean

Filter fields:

  • ?customer_native_name = string
  • ?domain = string
  • ?service_settings_name = string
  • ?service_name = string
  • ?customer_uuid = UUIDFilter
  • ?customer_abbreviation = string
  • ?tag = ModelMultipleChoiceField
  • ?customer_name = string
  • ?uuid = UUIDFilter
  • ?project_group = UUIDFilter
  • ?state = choice('Deleting', 'Deletion Scheduled', 'Erred', 'Offline', 'Online', 'Provisioning', 'Provisioning Scheduled', 'Resizing', 'Resizing Scheduled', 'Restarting', 'Restarting Scheduled', 'Starting', 'Starting Scheduled', 'Stopping', 'Stopping Scheduled')
  • ?rtag = ModelMultipleChoiceField
  • ?project_name = string
  • ?description = string
  • ?service_uuid = UUIDFilter
  • ?service_settings_uuid = UUIDFilter
  • ?customer = UUIDFilter
  • ?name = string
  • ?project_uuid = UUIDFilter
  • ?project = UUIDFilter
  • ?project_group_uuid = UUIDFilter
  • ?project_group_name = string

Order fields: created, customer_abbreviation, customer_name, customer_native_name, domain, name, project_group_name, project_name, state

/api/sharepoint-tenants/<uuid>/

Methods: GET, PUT, PATCH, DELETE

Supported fields for update:

  • namestring
  • description – string

Optional field query parameter (can be list) allows to limit what fields are returned. For example, given request /api/openstack-instances/<uuid>/?field=uuid&field=name you get response like this:

{
    "uuid": "90bcfe38b0124c9bbdadd617b5d739f5",
    "name": "Azure Virtual Machine"
}

/api/sharepoint-tenants/<uuid>/change_quotas/

Methods: POST, PUT

/api/sharepoint-tenants/<uuid>/unlink/

Methods: POST

/api/sharepoint-templates/

A filter backend that uses django-filter. Supported actions and methods:

/api/sharepoint-templates/

Methods: GET

Filter fields:

  • ?name = string

/api/sharepoint-templates/<uuid>/

Methods: GET

/api/sharepoint-site-collections/

A filter backend that uses django-filter. Supported actions and methods:

/api/sharepoint-site-collections/

Methods: GET, POST

Supported fields for creation:

  • templatelink to /api/sharepoint-templates/<uuid>/
  • userlink to /api/sharepoint-users/<uuid>/
  • storageinteger (Site collection size limit, MB)
  • namestring
  • descriptionstring
  • site_url – string

Filter fields:

  • ?template_uuid = UUIDFilter
  • ?name = string
  • ?template_code = string
  • ?template_name = string
  • ?type = MultipleChoiceFilter
  • ?access_url = string
  • ?user_uuid = UUIDFilter
  • ?tenant_uuid = UUIDFilter
  • ?description = string

Order fields: access_url, name

/api/sharepoint-site-collections/<uuid>/

Methods: GET, DELETE

/api/sharepoint-site-collections/<uuid>/change_quotas/

Methods: POST, PUT