GET /api/report_templates
List all report templates

GET /api/locations/:location_id/report_templates
List all report templates per location

GET /api/organizations/:organization_id/report_templates
List all report templates per organization

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

search
任意

結果のフィルター

Validations:

  • Must be a String

order
任意

Sort field and order, eg. ‘id DESC’

Validations:

  • Must be a String

page
任意

結果のページネーション

Validations:

  • Must be a String

per_page
任意

要求ごとのエントリー数

Validations:

  • Must be a String

検索フィールド

フィールド名 タイプ 設定可能な値
default true, false
location string
location_id integer
locked true, false
name string
organization string
organization_id integer
snippet true, false
template text

GET /api/report_templates/:id
Show a report template

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

id
必須

Validations:

  • Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.


POST /api/report_templates
Create a report template

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

report_template
必須

Validations:

  • Must be a Hash

report_template[name]
必須

Validations:

  • Must be a String

report_template[template]
必須

Validations:

  • Must be a String

report_template[snippet]
任意 , nil可

Validations:

  • Must be one of: true, false, 1, 0

report_template[audit_comment]
任意 , nil可

Validations:

  • Must be a String

report_template[locked]
任意 , nil可

テンプレートを編集用にロックするかどうか

Validations:

  • Must be one of: true, false, 1, 0

report_template[default]
任意 , nil可

Whether or not the template is added automatically to new organizations and locations

Validations:

  • Must be one of: true, false, 1, 0

report_template[location_ids]
任意 , nil可

ロケーションを指定された ID に置き換えます

Validations:

  • Must be an array of any type

report_template[organization_ids]
任意 , nil可

組織を指定された ID に置き換えます。

Validations:

  • Must be an array of any type


POST /api/report_templates/import
Import a report template

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

report_template
必須

Validations:

  • Must be a Hash

report_template[name]
任意

テンプレート名

Validations:

  • Must be a String

report_template[template]
任意

メタデータを含むテンプレートコンテンツ

Validations:

  • Must be a String

report_template[location_ids]
任意 , nil可

ロケーションを指定された ID に置き換えます

Validations:

  • Must be an array of any type

report_template[organization_ids]
任意 , nil可

組織を指定された ID に置き換えます。

Validations:

  • Must be an array of any type

options
任意

Validations:

  • Must be a Hash

options[force]
任意 , nil可

ロックしたテンプレートを更新したい場合に使用

Validations:

  • Must be one of: true, false, 1, 0

options[associate]
任意 , nil可

テンプレートがオブジェクトをメタデータに基づいて関連付ける場合を決定します。new は新規テンプレートが作成中であることを意味します。always は、新規および更新中の既存のテンプレートを意味します。never はメタデータを無視します

Validations:

  • Must be one of: new, always, never.

options[lock]
任意 , nil可

インポートされたテンプレートをロックします (デフォルトは false)

Validations:

  • Must be one of: true, false, 1, 0

options[default]
任意 , nil可

makes the template default meaning it will be automatically associated with newly created organizations and locations (false by default)

Validations:

  • Must be one of: true, false, 1, 0


GET /api/report_templates/revision

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

version
任意

テンプレートのバージョン

Validations:

  • Must be a String


PUT /api/report_templates/:id
Update a report template

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

id
必須

Validations:

  • Must be a String

report_template
必須

Validations:

  • Must be a Hash

report_template[name]
任意

Validations:

  • Must be a String

report_template[template]
任意

Validations:

  • Must be a String

report_template[snippet]
任意 , nil可

Validations:

  • Must be one of: true, false, 1, 0

report_template[audit_comment]
任意 , nil可

Validations:

  • Must be a String

report_template[locked]
任意 , nil可

テンプレートを編集用にロックするかどうか

Validations:

  • Must be one of: true, false, 1, 0

report_template[default]
任意 , nil可

Whether or not the template is added automatically to new organizations and locations

Validations:

  • Must be one of: true, false, 1, 0

report_template[location_ids]
任意 , nil可

ロケーションを指定された ID に置き換えます

Validations:

  • Must be an array of any type

report_template[organization_ids]
任意 , nil可

組織を指定された ID に置き換えます。

Validations:

  • Must be an array of any type


DELETE /api/report_templates/:id
Delete a report template

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

id
必須

Validations:

  • Must be a String


POST /api/report_templates/:id/clone
テンプレートのクローン

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

id
必須

Validations:

  • Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.

report_template
必須

Validations:

  • Must be a Hash

report_template[name]
必須

テンプレート名

Validations:

  • Must be a String


GET /api/report_templates/:id/export
Export a report template to ERB

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

id
必須

Validations:

  • Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.


POST /api/report_templates/:id/generate
Generate a report template

パラメーター

パラメーター名 記述
location_id
任意

ロケーション別のスコープ

Validations:

  • Must be a Integer

organization_id
任意

組織別のスコープ

Validations:

  • Must be a Integer

id
必須

Validations:

  • Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.

input_values
任意

Hash of input values where key is the name of input, value is the value for this input

Validations:

  • Must be a Hash