service_instances
Creates, updates, deletes, gets or lists a service_instances resource.
Overview​
| Name | service_instances |
| Type | Resource |
| Id | netlify.services.service_instances |
Fields​
The following fields are returned by SELECT queries:
- get
- list
| Name | Datatype | Description |
|---|---|---|
id | string | |
service_name | string | |
auth_url | string | |
config | string | (opaque JSON object) |
created_at | string (dateTime) | |
env | string | (opaque JSON object) |
external_attributes | string | (opaque JSON object) |
service_path | string | |
service_slug | string | |
snippets | array | |
updated_at | string (dateTime) | |
url | string |
| Name | Datatype | Description |
|---|---|---|
id | string | |
service_name | string | |
auth_url | string | |
config | string | (opaque JSON object) |
created_at | string (dateTime) | |
env | string | (opaque JSON object) |
external_attributes | string | (opaque JSON object) |
service_path | string | |
service_slug | string | |
snippets | array | |
updated_at | string (dateTime) | |
url | string |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | site_id, addon, instance_id | ||
list | select | site_id | ||
create | insert | site_id, addon, config | ||
update | replace | site_id, addon, instance_id, config | ||
delete | delete | site_id, addon, instance_id |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
addon | string | |
instance_id | string | |
site_id | string |
SELECT examples​
- get
- list
OK
SELECT
id,
service_name,
auth_url,
config,
created_at,
env,
external_attributes,
service_path,
service_slug,
snippets,
updated_at,
url
FROM netlify.services.service_instances
WHERE site_id = '{{ site_id }}' -- required
AND addon = '{{ addon }}' -- required
AND instance_id = '{{ instance_id }}' -- required
;
OK
SELECT
id,
service_name,
auth_url,
config,
created_at,
env,
external_attributes,
service_path,
service_slug,
snippets,
updated_at,
url
FROM netlify.services.service_instances
WHERE site_id = '{{ site_id }}' -- required
;
INSERT examples​
- create
- Manifest
No description available.
INSERT INTO netlify.services.service_instances (
config,
site_id,
addon
)
SELECT
'{{ config }}' /* required */,
'{{ site_id }}',
'{{ addon }}'
RETURNING
id,
service_name,
auth_url,
config,
created_at,
env,
external_attributes,
service_path,
service_slug,
snippets,
updated_at,
url
;
# Description fields are for documentation purposes
- name: service_instances
props:
- name: site_id
value: "{{ site_id }}"
description: Required parameter for the service_instances resource.
- name: addon
value: "{{ addon }}"
description: Required parameter for the service_instances resource.
- name: config
value: "{{ config }}"
description: |
Add-on specific configuration object; sent verbatim as the request body.
REPLACE examples​
- update
No description available.
REPLACE netlify.services.service_instances
SET
config = '{{ config }}'
WHERE
site_id = '{{ site_id }}' --required
AND addon = '{{ addon }}' --required
AND instance_id = '{{ instance_id }}' --required
AND config = '{{ config }}' --required;
DELETE examples​
- delete
No description available.
DELETE FROM netlify.services.service_instances
WHERE site_id = '{{ site_id }}' --required
AND addon = '{{ addon }}' --required
AND instance_id = '{{ instance_id }}' --required
;