- 基本情報
- 認証
- Swagger の定義
- Orchestrator API
- プラットフォーム管理 API

Orchestrator API ガイド
スケジュールの要求
動的なロボット割り当てを使用してスケジュールを開始する
以下の要求では、APITest という名前のスケジュールを GMT 標準時のタイム ゾーンに作成し、5 か月ごとに日曜日にトリガーすることができます。
StartStrategy パラメーターを使用すると、ジョブの実行方法を選択できます。
StartStrategy に設定可能な値
| 値 (Value) | 名前 | 説明 | フォルダー コンテキスト |
|---|---|---|---|
-1 | すべてのロボット | プロセスのロボット グループに存在する各ロボットに対して 1 回、ジョブを実行します。 | クラシック |
0 | カスタム ロボット | 指定した各ロボットで 1 回、ジョブを実行します。ロボットを指定するには、ロボット ID を ExecutorRobots の値として含めます。例: '"ExecutorRobots" : {"Id" : 44881 | クラシック |
1 | 1 台のロボット | プロセスが存在するフォルダーへのアクセス権を持つ任意のユーザーの、動的に選択されたロボット上でジョブを実行します。 また、MachineRobots で指定したロボットで実行するようにジョブを設定することもできます。以下の要求本文で例をご確認ください。 | モダン |
| その他の任意の数 | 動的に割り当て | 指定された数のジョブを作成し、プロセスのモダン フォルダーで利用可能なロボット、またはクラシック フォルダーの環境内のロボットから、ジョブを実行するロボットを動的に選択します。モダン フォルダーの場合は、list パラメーター を使用して、1 つ以上のマシン テンプレート、ロボット、またはマシン テンプレートとロボットの両方を指定することもできます MachineRobots。この場合、 StartStrategy 値は、指定したロボットまたはロボットと機械の組み合わせのそれぞれでジョブを実行する回数を表します。これはクラシック フォルダーではできず、指定した場合、 ExecutorRobots パラメーターは無視されます。 | クラシックまたはモダン |
POST
https://{yourDomain}/odata/ProcessSchedules
要求ヘッダー
| キー | 値 (Value) |
|---|---|
| 認可 | Bearer |
要求本文
{
"Name":"ApiTest",
"ReleaseId":75,
"ReleaseName":"BlankProcess_DocEnv",
"StartProcessCron":"0 0 0 ? 1/5 SUN *",
"StartProcessCronDetails":"{\"type\":4,\"minutely\":{},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[{\"id\":\"SUN\",\"weekly\":\"Sunday\",\"monthly\":\"Sunday\"}],\"atMinute\":0,\"atHour\":0,\"frequencyInMonths\":\"5\"},\"advancedCronExpression\":\"\"}",
"StartStrategy":15,
"ExecutorRobots":[],
"MachineRobots":[
{
"MachineId":null,
"MachineName":null,
"RobotId":44880,
"RobotUserName":"acme\\john.doe"
}
],
"StopProcessExpression":"",
"StopStrategy":null,
"TimeZoneId":"GMT Standard Time"
}
{
"Name":"ApiTest",
"ReleaseId":75,
"ReleaseName":"BlankProcess_DocEnv",
"StartProcessCron":"0 0 0 ? 1/5 SUN *",
"StartProcessCronDetails":"{\"type\":4,\"minutely\":{},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[{\"id\":\"SUN\",\"weekly\":\"Sunday\",\"monthly\":\"Sunday\"}],\"atMinute\":0,\"atHour\":0,\"frequencyInMonths\":\"5\"},\"advancedCronExpression\":\"\"}",
"StartStrategy":15,
"ExecutorRobots":[],
"MachineRobots":[
{
"MachineId":null,
"MachineName":null,
"RobotId":44880,
"RobotUserName":"acme\\john.doe"
}
],
"StopProcessExpression":"",
"StopStrategy":null,
"TimeZoneId":"GMT Standard Time"
}
TimeZoneId パラメーターの正しい値を抽出するには、/odata/Settings/UiPath.Server.Configuration.OData.GetTimezones エンドポイントにGET要求を送信します。応答で自分のタイム ゾーンのエントリを見つけ、 Value フィールドの文字列をコピーします。その後、スケジュールを作成するときに、この文字列を要求本文の TimeZoneId パラメーターの値として使用します。
応答コード
200 OK
応答本文
{
"@odata.context": "https://{yourDomain}/odata/$metadata#ProcessSchedules/$entity",
"Enabled": true,
"Name": "ApiTest",
"ReleaseId": 75,
"ReleaseKey": "00000000-0000-0000-0000-000000000000",
"ReleaseName": null,
"PackageName": null,
"EnvironmentName": null,
"EnvironmentId": "0",
"StartProcessCron": "0 0 0 ? 1/5 SUN *",
"StartProcessCronDetails": "{\"type\":4,\"minutely\":{},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[{\"id\":\"SUN\",\"weekly\":\"Sunday\",\"monthly\":\"Sunday\"}],\"atMinute\":0,\"atHour\":0,\"frequencyInMonths\":\"5\"},\"advancedCronExpression\":\"\"}",
"StartProcessCronSummary": null,
"StartProcessNextOccurrence": null,
"StartStrategy": 15,
"StopProcessExpression": "",
"StopStrategy": null,
"ExternalJobKey": "8cda4b35-e835-445b-b477-1ea0961d62e5",
"TimeZoneId": "GMT Standard Time",
"TimeZoneIana": "Europe/London",
"UseCalendar": false,
"StopProcessDate": null,
"InputArguments": "{}",
"Id": 43
}
{
"@odata.context": "https://{yourDomain}/odata/$metadata#ProcessSchedules/$entity",
"Enabled": true,
"Name": "ApiTest",
"ReleaseId": 75,
"ReleaseKey": "00000000-0000-0000-0000-000000000000",
"ReleaseName": null,
"PackageName": null,
"EnvironmentName": null,
"EnvironmentId": "0",
"StartProcessCron": "0 0 0 ? 1/5 SUN *",
"StartProcessCronDetails": "{\"type\":4,\"minutely\":{},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[{\"id\":\"SUN\",\"weekly\":\"Sunday\",\"monthly\":\"Sunday\"}],\"atMinute\":0,\"atHour\":0,\"frequencyInMonths\":\"5\"},\"advancedCronExpression\":\"\"}",
"StartProcessCronSummary": null,
"StartProcessNextOccurrence": null,
"StartStrategy": 15,
"StopProcessExpression": "",
"StopStrategy": null,
"ExternalJobKey": "8cda4b35-e835-445b-b477-1ea0961d62e5",
"TimeZoneId": "GMT Standard Time",
"TimeZoneIana": "Europe/London",
"UseCalendar": false,
"StopProcessDate": null,
"InputArguments": "{}",
"Id": 43
}
入力パラメーター値を使用してスケジュールを開始する
/odata/ProcessSchedules エンドポイントに対する以下の POST 要求では、ID が 55 のプロセス上に「API_schedule_test」という名前の有効なスケジュールを作成すると同時に、プロセスの一部のパラメーターにカスタム値を追加できます。このスケジュールは、利用可能なすべてのロボットで 5 分ごとに開始されます。非稼働日は考慮されません。
入力パラメーターの JSON 表現の全長で最大 10,000 文字を入力できます。これには、引数名、エスケープされたすべての文字、スペース、角かっこ、引数の値が含まれます。
POST
https://{yourDomain}/odata/ProcessSchedules
要求ヘッダー
| キー | 値 (Value) |
|---|---|
| 認可 | Bearer |
要求本文
{
"Enabled": true,
"Name": "API_schedule_test",
"ReleaseId": 55,
"ReleaseKey": "429cf1cc-283c-424f-a935-43f72c2ca719",
"ReleaseName": "input_output_test_DocEnv",
"PackageName": "input_output_test",
"EnvironmentName": "DocEnv",
"EnvironmentId": "7",
"StartProcessCron": "0 0/5 * 1/1 * ? *",
"StartProcessCronDetails": "{\"type\":0,\"minutely\":{\"atMinute\":5},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[]},\"advancedCronExpression\":\"\"}",
"StartProcessCronSummary": "Every 5 minutes",
"StartProcessNextOccurrence": null,
"StartStrategy": 0,
"StopProcessExpression": "",
"StopStrategy": null,
"ExternalJobKey": "af486c19-c797-48cd-b586-cfb7a12110a2",
"TimeZoneId": "Morocco Standard Time",
"TimeZoneIana": "Africa/Casablanca",
"UseCalendar": false,
"StopProcessDate": null,
"InputArguments": "{\"arrayStrings\":[\"test\",\"test\"],\"age\":666,\"trueOrFalse\":false,\"dateNow\":\"2012-04-23T18:25:43.511Z\",\"stringNew\":\"stringTest\",\"DoubleTest\":7.555555}",
"Id": 37
}
{
"Enabled": true,
"Name": "API_schedule_test",
"ReleaseId": 55,
"ReleaseKey": "429cf1cc-283c-424f-a935-43f72c2ca719",
"ReleaseName": "input_output_test_DocEnv",
"PackageName": "input_output_test",
"EnvironmentName": "DocEnv",
"EnvironmentId": "7",
"StartProcessCron": "0 0/5 * 1/1 * ? *",
"StartProcessCronDetails": "{\"type\":0,\"minutely\":{\"atMinute\":5},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[]},\"advancedCronExpression\":\"\"}",
"StartProcessCronSummary": "Every 5 minutes",
"StartProcessNextOccurrence": null,
"StartStrategy": 0,
"StopProcessExpression": "",
"StopStrategy": null,
"ExternalJobKey": "af486c19-c797-48cd-b586-cfb7a12110a2",
"TimeZoneId": "Morocco Standard Time",
"TimeZoneIana": "Africa/Casablanca",
"UseCalendar": false,
"StopProcessDate": null,
"InputArguments": "{\"arrayStrings\":[\"test\",\"test\"],\"age\":666,\"trueOrFalse\":false,\"dateNow\":\"2012-04-23T18:25:43.511Z\",\"stringNew\":\"stringTest\",\"DoubleTest\":7.555555}",
"Id": 37
}
TimeZoneId パラメーターの正しい値を抽出するには、/odata/Settings/UiPath.Server.Configuration.OData.GetTimezones エンドポイントにGET要求を送信します。応答で自分のタイム ゾーンのエントリを見つけ、 Value フィールドの文字列をコピーします。その後、スケジュールを作成するときに、この文字列を要求本文の TimeZoneId パラメーターの値として使用します。
応答コード
200 OK
応答本文
{
"@odata.context": "https://{yourDomain}/odata/$metadata#ProcessSchedules/$entity",
"Enabled": true,
"Name": "API_schedule_test",
"ReleaseId": 55,
"ReleaseKey": "00000000-0000-0000-0000-000000000000",
"ReleaseName": null,
"PackageName": null,
"EnvironmentName": null,
"EnvironmentId": "0",
"StartProcessCron": "0 0/5 * 1/1 * ? *",
"StartProcessCronDetails": "{\"type\":0,\"minutely\":{\"atMinute\":5},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[]},\"advancedCronExpression\":\"\"}",
"StartProcessCronSummary": "Every 5 minutes",
"StartProcessNextOccurrence": null,
"StartStrategy": 0,
"StopProcessExpression": "",
"StopStrategy": null,
"ExternalJobKey": "7ecbff8d-832d-41e1-a3ed-aee0957caffe",
"TimeZoneId": "Morocco Standard Time",
"TimeZoneIana": "Africa/Casablanca",
"UseCalendar": false,
"StopProcessDate": null,
"InputArguments": "{\"arrayStrings\":[\"test\",\"test\"],\"age\":666,\"trueOrFalse\":false,\"dateNow\":\"2012-04-23T18:25:43.511Z\",\"stringNew\":\"stringTest\",\"DoubleTest\":7.555555,\"inOutTry\":\"2012-04-23T18:25:43.511Z\"}",
"Id": 37
}
{
"@odata.context": "https://{yourDomain}/odata/$metadata#ProcessSchedules/$entity",
"Enabled": true,
"Name": "API_schedule_test",
"ReleaseId": 55,
"ReleaseKey": "00000000-0000-0000-0000-000000000000",
"ReleaseName": null,
"PackageName": null,
"EnvironmentName": null,
"EnvironmentId": "0",
"StartProcessCron": "0 0/5 * 1/1 * ? *",
"StartProcessCronDetails": "{\"type\":0,\"minutely\":{\"atMinute\":5},\"hourly\":{},\"daily\":{},\"weekly\":{\"weekdays\":[]},\"monthly\":{\"weekdays\":[]},\"advancedCronExpression\":\"\"}",
"StartProcessCronSummary": "Every 5 minutes",
"StartProcessNextOccurrence": null,
"StartStrategy": 0,
"StopProcessExpression": "",
"StopStrategy": null,
"ExternalJobKey": "7ecbff8d-832d-41e1-a3ed-aee0957caffe",
"TimeZoneId": "Morocco Standard Time",
"TimeZoneIana": "Africa/Casablanca",
"UseCalendar": false,
"StopProcessDate": null,
"InputArguments": "{\"arrayStrings\":[\"test\",\"test\"],\"age\":666,\"trueOrFalse\":false,\"dateNow\":\"2012-04-23T18:25:43.511Z\",\"stringNew\":\"stringTest\",\"DoubleTest\":7.555555,\"inOutTry\":\"2012-04-23T18:25:43.511Z\"}",
"Id": 37
}