@taskcluster/client-web 100.4.0 → 100.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10,70 +10,63 @@ export default class Auth extends Client {
10
10
  exchangePrefix: '',
11
11
  ...options,
12
12
  });
13
- this.ping.entry = {"args":[],"category":"Monitoring","method":"get","name":"ping","query":[],"route":"/ping","stability":"stable","type":"function"}; // eslint-disable-line
14
- this.lbheartbeat.entry = {"args":[],"category":"Monitoring","method":"get","name":"lbheartbeat","query":[],"route":"/__lbheartbeat__","stability":"stable","type":"function"}; // eslint-disable-line
15
- this.version.entry = {"args":[],"category":"Monitoring","method":"get","name":"version","query":[],"route":"/__version__","stability":"stable","type":"function"}; // eslint-disable-line
16
- this.listClients.entry = {"args":[],"category":"Clients","method":"get","name":"listClients","output":true,"query":["prefix","continuationToken","limit"],"route":"/clients/","scopes":"auth:list-clients","stability":"stable","type":"function"}; // eslint-disable-line
17
- this.client.entry = {"args":["clientId"],"category":"Clients","method":"get","name":"client","output":true,"query":[],"route":"/clients/<clientId>","scopes":"auth:get-client:<clientId>","stability":"stable","type":"function"}; // eslint-disable-line
18
- this.createClient.entry = {"args":["clientId"],"category":"Clients","input":true,"method":"put","name":"createClient","output":true,"query":[],"route":"/clients/<clientId>","scopes":{"AllOf":["auth:create-client:<clientId>",{"each":"<scope>","for":"scope","in":"scopes"}]},"stability":"stable","type":"function"}; // eslint-disable-line
19
- this.getEntityHistory.entry = {"args":["entityType","entityId"],"category":"Audit","method":"get","name":"getEntityHistory","output":true,"query":["continuationToken","limit"],"route":"/audit/<entityType>/<entityId>","scopes":"auth:audit-history:<entityType>","stability":"stable","type":"function"}; // eslint-disable-line
20
- this.listAuditHistory.entry = {"args":["clientId"],"category":"Audit","method":"get","name":"listAuditHistory","output":true,"query":["continuationToken","limit"],"route":"/clients/<clientId>/audit","scopes":"auth:client-audit-history:<clientId>","stability":"stable","type":"function"}; // eslint-disable-line
21
- this.resetAccessToken.entry = {"args":["clientId"],"category":"Clients","method":"post","name":"resetAccessToken","output":true,"query":[],"route":"/clients/<clientId>/reset","scopes":"auth:reset-access-token:<clientId>","stability":"stable","type":"function"}; // eslint-disable-line
22
- this.updateClient.entry = {"args":["clientId"],"category":"Clients","input":true,"method":"post","name":"updateClient","output":true,"query":[],"route":"/clients/<clientId>","scopes":{"AllOf":["auth:update-client:<clientId>",{"each":"<scope>","for":"scope","in":"scopesAdded"}]},"stability":"stable","type":"function"}; // eslint-disable-line
23
- this.enableClient.entry = {"args":["clientId"],"category":"Clients","method":"post","name":"enableClient","output":true,"query":[],"route":"/clients/<clientId>/enable","scopes":"auth:enable-client:<clientId>","stability":"stable","type":"function"}; // eslint-disable-line
24
- this.disableClient.entry = {"args":["clientId"],"category":"Clients","method":"post","name":"disableClient","output":true,"query":[],"route":"/clients/<clientId>/disable","scopes":"auth:disable-client:<clientId>","stability":"stable","type":"function"}; // eslint-disable-line
25
- this.deleteClient.entry = {"args":["clientId"],"category":"Clients","method":"delete","name":"deleteClient","query":[],"route":"/clients/<clientId>","scopes":"auth:delete-client:<clientId>","stability":"stable","type":"function"}; // eslint-disable-line
26
- this.listRoles.entry = {"args":[],"category":"Roles","method":"get","name":"listRoles","output":true,"query":[],"route":"/roles/","scopes":"auth:list-roles","stability":"stable","type":"function"}; // eslint-disable-line
27
- this.listRoles2.entry = {"args":[],"category":"Roles","method":"get","name":"listRoles2","output":true,"query":["continuationToken","limit"],"route":"/roles2/","scopes":"auth:list-roles","stability":"stable","type":"function"}; // eslint-disable-line
28
- this.listRoleIds.entry = {"args":[],"category":"Roles","method":"get","name":"listRoleIds","output":true,"query":["continuationToken","limit"],"route":"/roleids/","scopes":"auth:list-roles","stability":"stable","type":"function"}; // eslint-disable-line
29
- this.role.entry = {"args":["roleId"],"category":"Roles","method":"get","name":"role","output":true,"query":[],"route":"/roles/<roleId>","scopes":"auth:get-role:<roleId>","stability":"stable","type":"function"}; // eslint-disable-line
30
- this.createRole.entry = {"args":["roleId"],"category":"Roles","input":true,"method":"put","name":"createRole","output":true,"query":[],"route":"/roles/<roleId>","scopes":{"AllOf":["auth:create-role:<roleId>",{"each":"<scope>","for":"scope","in":"scopes"}]},"stability":"stable","type":"function"}; // eslint-disable-line
31
- this.updateRole.entry = {"args":["roleId"],"category":"Roles","input":true,"method":"post","name":"updateRole","output":true,"query":[],"route":"/roles/<roleId>","scopes":{"AllOf":["auth:update-role:<roleId>",{"each":"<scope>","for":"scope","in":"scopesAdded"}]},"stability":"stable","type":"function"}; // eslint-disable-line
32
- this.deleteRole.entry = {"args":["roleId"],"category":"Roles","method":"delete","name":"deleteRole","query":[],"route":"/roles/<roleId>","scopes":"auth:delete-role:<roleId>","stability":"stable","type":"function"}; // eslint-disable-line
33
- this.expandScopes.entry = {"args":[],"category":"Scopes and Auth","input":true,"method":"post","name":"expandScopes","output":true,"query":[],"route":"/scopes/expand","scopes":"auth:expand-scopes","stability":"stable","type":"function"}; // eslint-disable-line
34
- this.currentScopes.entry = {"args":[],"category":"Scopes and Auth","method":"get","name":"currentScopes","output":true,"query":[],"route":"/scopes/current","scopes":"auth:current-scopes","stability":"stable","type":"function"}; // eslint-disable-line
35
- this.awsS3Credentials.entry = {"args":["level","bucket","prefix"],"category":"AWS Credentials","method":"get","name":"awsS3Credentials","output":true,"query":["format"],"route":"/aws/s3/<level>/<bucket>/<prefix>","scopes":{"else":"auth:aws-s3:read-write:<bucket>/<prefix>","if":"levelIsReadOnly","then":{"AnyOf":["auth:aws-s3:read-only:<bucket>/<prefix>","auth:aws-s3:read-write:<bucket>/<prefix>"]}},"stability":"stable","type":"function"}; // eslint-disable-line
36
- this.azureAccounts.entry = {"args":[],"category":"Azure Credentials","method":"get","name":"azureAccounts","output":true,"query":[],"route":"/azure/accounts","scopes":"auth:azure-table:list-accounts","stability":"deprecated","type":"function"}; // eslint-disable-line
37
- this.azureTables.entry = {"args":["account"],"category":"Azure Credentials","method":"get","name":"azureTables","output":true,"query":["continuationToken"],"route":"/azure/<account>/tables","scopes":"auth:azure-table:list-tables:<account>","stability":"deprecated","type":"function"}; // eslint-disable-line
38
- this.azureTableSAS.entry = {"args":["account","table","level"],"category":"Azure Credentials","method":"get","name":"azureTableSAS","output":true,"query":[],"route":"/azure/<account>/table/<table>/<level>","scopes":{"else":"auth:azure-table:read-write:<account>/<table>","if":"levelIsReadOnly","then":{"AnyOf":["auth:azure-table:read-only:<account>/<table>","auth:azure-table:read-write:<account>/<table>"]}},"stability":"deprecated","type":"function"}; // eslint-disable-line
39
- this.azureContainers.entry = {"args":["account"],"category":"Azure Credentials","method":"get","name":"azureContainers","output":true,"query":["continuationToken"],"route":"/azure/<account>/containers","scopes":"auth:azure-container:list-containers:<account>","stability":"deprecated","type":"function"}; // eslint-disable-line
40
- this.azureContainerSAS.entry = {"args":["account","container","level"],"category":"Azure Credentials","method":"get","name":"azureContainerSAS","output":true,"query":[],"route":"/azure/<account>/containers/<container>/<level>","scopes":{"else":"auth:azure-container:read-write:<account>/<container>","if":"levelIsReadOnly","then":{"AnyOf":["auth:azure-container:read-only:<account>/<container>","auth:azure-container:read-write:<account>/<container>"]}},"stability":"deprecated","type":"function"}; // eslint-disable-line
41
- this.sentryDSN.entry = {"args":["project"],"category":"Sentry Credentials","method":"get","name":"sentryDSN","output":true,"query":[],"route":"/sentry/<project>/dsn","scopes":"auth:sentry:<project>","stability":"stable","type":"function"}; // eslint-disable-line
42
- this.websocktunnelToken.entry = {"args":["wstAudience","wstClient"],"category":"Websocktunnel Credentials","method":"get","name":"websocktunnelToken","output":true,"query":[],"route":"/websocktunnel/<wstAudience>/<wstClient>","scopes":"auth:websocktunnel-token:<wstAudience>/<wstClient>","stability":"stable","type":"function"}; // eslint-disable-line
43
- this.gcpCredentials.entry = {"args":["projectId","serviceAccount"],"category":"GCP Credentials","method":"get","name":"gcpCredentials","output":true,"query":[],"route":"/gcp/credentials/<projectId>/<serviceAccount>","scopes":"auth:gcp:access-token:<projectId>/<serviceAccount>","stability":"stable","type":"function"}; // eslint-disable-line
44
- this.authenticateHawk.entry = {"args":[],"category":"Scopes and Auth","input":true,"method":"post","name":"authenticateHawk","output":true,"query":[],"route":"/authenticate-hawk","stability":"stable","type":"function"}; // eslint-disable-line
45
- this.testAuthenticate.entry = {"args":[],"category":"Scopes and Auth","input":true,"method":"post","name":"testAuthenticate","output":true,"query":[],"route":"/test-authenticate","stability":"stable","type":"function"}; // eslint-disable-line
46
- this.testAuthenticateGet.entry = {"args":[],"category":"Scopes and Auth","method":"get","name":"testAuthenticateGet","output":true,"query":[],"route":"/test-authenticate-get/","stability":"stable","type":"function"}; // eslint-disable-line
47
- this.heartbeat.entry = {"args":[],"category":"Monitoring","method":"get","name":"heartbeat","query":[],"route":"/__heartbeat__","stability":"stable","type":"function"}; // eslint-disable-line
48
- }
49
- /* eslint-disable max-len */
13
+ this.ping.entry = {"args":[],"category":"Monitoring","method":"get","name":"ping","query":[],"route":"/ping","stability":"stable","type":"function"};
14
+ this.lbheartbeat.entry = {"args":[],"category":"Monitoring","method":"get","name":"lbheartbeat","query":[],"route":"/__lbheartbeat__","stability":"stable","type":"function"};
15
+ this.version.entry = {"args":[],"category":"Monitoring","method":"get","name":"version","query":[],"route":"/__version__","stability":"stable","type":"function"};
16
+ this.listClients.entry = {"args":[],"category":"Clients","method":"get","name":"listClients","output":true,"query":["prefix","continuationToken","limit"],"route":"/clients/","scopes":"auth:list-clients","stability":"stable","type":"function"};
17
+ this.client.entry = {"args":["clientId"],"category":"Clients","method":"get","name":"client","output":true,"query":[],"route":"/clients/<clientId>","scopes":"auth:get-client:<clientId>","stability":"stable","type":"function"};
18
+ this.createClient.entry = {"args":["clientId"],"category":"Clients","input":true,"method":"put","name":"createClient","output":true,"query":[],"route":"/clients/<clientId>","scopes":{"AllOf":["auth:create-client:<clientId>",{"each":"<scope>","for":"scope","in":"scopes"}]},"stability":"stable","type":"function"};
19
+ this.getEntityHistory.entry = {"args":["entityType","entityId"],"category":"Audit","method":"get","name":"getEntityHistory","output":true,"query":["continuationToken","limit"],"route":"/audit/<entityType>/<entityId>","scopes":"auth:audit-history:<entityType>","stability":"stable","type":"function"};
20
+ this.listAuditHistory.entry = {"args":["clientId"],"category":"Audit","method":"get","name":"listAuditHistory","output":true,"query":["continuationToken","limit"],"route":"/clients/<clientId>/audit","scopes":"auth:client-audit-history:<clientId>","stability":"stable","type":"function"};
21
+ this.resetAccessToken.entry = {"args":["clientId"],"category":"Clients","method":"post","name":"resetAccessToken","output":true,"query":[],"route":"/clients/<clientId>/reset","scopes":"auth:reset-access-token:<clientId>","stability":"stable","type":"function"};
22
+ this.updateClient.entry = {"args":["clientId"],"category":"Clients","input":true,"method":"post","name":"updateClient","output":true,"query":[],"route":"/clients/<clientId>","scopes":{"AllOf":["auth:update-client:<clientId>",{"each":"<scope>","for":"scope","in":"scopesAdded"}]},"stability":"stable","type":"function"};
23
+ this.enableClient.entry = {"args":["clientId"],"category":"Clients","method":"post","name":"enableClient","output":true,"query":[],"route":"/clients/<clientId>/enable","scopes":"auth:enable-client:<clientId>","stability":"stable","type":"function"};
24
+ this.disableClient.entry = {"args":["clientId"],"category":"Clients","method":"post","name":"disableClient","output":true,"query":[],"route":"/clients/<clientId>/disable","scopes":"auth:disable-client:<clientId>","stability":"stable","type":"function"};
25
+ this.deleteClient.entry = {"args":["clientId"],"category":"Clients","method":"delete","name":"deleteClient","query":[],"route":"/clients/<clientId>","scopes":"auth:delete-client:<clientId>","stability":"stable","type":"function"};
26
+ this.listRoles.entry = {"args":[],"category":"Roles","method":"get","name":"listRoles","output":true,"query":[],"route":"/roles/","scopes":"auth:list-roles","stability":"stable","type":"function"};
27
+ this.listRoles2.entry = {"args":[],"category":"Roles","method":"get","name":"listRoles2","output":true,"query":["continuationToken","limit"],"route":"/roles2/","scopes":"auth:list-roles","stability":"stable","type":"function"};
28
+ this.listRoleIds.entry = {"args":[],"category":"Roles","method":"get","name":"listRoleIds","output":true,"query":["continuationToken","limit"],"route":"/roleids/","scopes":"auth:list-roles","stability":"stable","type":"function"};
29
+ this.role.entry = {"args":["roleId"],"category":"Roles","method":"get","name":"role","output":true,"query":[],"route":"/roles/<roleId>","scopes":"auth:get-role:<roleId>","stability":"stable","type":"function"};
30
+ this.createRole.entry = {"args":["roleId"],"category":"Roles","input":true,"method":"put","name":"createRole","output":true,"query":[],"route":"/roles/<roleId>","scopes":{"AllOf":["auth:create-role:<roleId>",{"each":"<scope>","for":"scope","in":"scopes"}]},"stability":"stable","type":"function"};
31
+ this.updateRole.entry = {"args":["roleId"],"category":"Roles","input":true,"method":"post","name":"updateRole","output":true,"query":[],"route":"/roles/<roleId>","scopes":{"AllOf":["auth:update-role:<roleId>",{"each":"<scope>","for":"scope","in":"scopesAdded"}]},"stability":"stable","type":"function"};
32
+ this.deleteRole.entry = {"args":["roleId"],"category":"Roles","method":"delete","name":"deleteRole","query":[],"route":"/roles/<roleId>","scopes":"auth:delete-role:<roleId>","stability":"stable","type":"function"};
33
+ this.expandScopes.entry = {"args":[],"category":"Scopes and Auth","input":true,"method":"post","name":"expandScopes","output":true,"query":[],"route":"/scopes/expand","scopes":"auth:expand-scopes","stability":"stable","type":"function"};
34
+ this.currentScopes.entry = {"args":[],"category":"Scopes and Auth","method":"get","name":"currentScopes","output":true,"query":[],"route":"/scopes/current","scopes":"auth:current-scopes","stability":"stable","type":"function"};
35
+ this.awsS3Credentials.entry = {"args":["level","bucket","prefix"],"category":"AWS Credentials","method":"get","name":"awsS3Credentials","output":true,"query":["format"],"route":"/aws/s3/<level>/<bucket>/<prefix>","scopes":{"else":"auth:aws-s3:read-write:<bucket>/<prefix>","if":"levelIsReadOnly","then":{"AnyOf":["auth:aws-s3:read-only:<bucket>/<prefix>","auth:aws-s3:read-write:<bucket>/<prefix>"]}},"stability":"stable","type":"function"};
36
+ this.azureAccounts.entry = {"args":[],"category":"Azure Credentials","method":"get","name":"azureAccounts","output":true,"query":[],"route":"/azure/accounts","scopes":"auth:azure-table:list-accounts","stability":"deprecated","type":"function"};
37
+ this.azureTables.entry = {"args":["account"],"category":"Azure Credentials","method":"get","name":"azureTables","output":true,"query":["continuationToken"],"route":"/azure/<account>/tables","scopes":"auth:azure-table:list-tables:<account>","stability":"deprecated","type":"function"};
38
+ this.azureTableSAS.entry = {"args":["account","table","level"],"category":"Azure Credentials","method":"get","name":"azureTableSAS","output":true,"query":[],"route":"/azure/<account>/table/<table>/<level>","scopes":{"else":"auth:azure-table:read-write:<account>/<table>","if":"levelIsReadOnly","then":{"AnyOf":["auth:azure-table:read-only:<account>/<table>","auth:azure-table:read-write:<account>/<table>"]}},"stability":"deprecated","type":"function"};
39
+ this.azureContainers.entry = {"args":["account"],"category":"Azure Credentials","method":"get","name":"azureContainers","output":true,"query":["continuationToken"],"route":"/azure/<account>/containers","scopes":"auth:azure-container:list-containers:<account>","stability":"deprecated","type":"function"};
40
+ this.azureContainerSAS.entry = {"args":["account","container","level"],"category":"Azure Credentials","method":"get","name":"azureContainerSAS","output":true,"query":[],"route":"/azure/<account>/containers/<container>/<level>","scopes":{"else":"auth:azure-container:read-write:<account>/<container>","if":"levelIsReadOnly","then":{"AnyOf":["auth:azure-container:read-only:<account>/<container>","auth:azure-container:read-write:<account>/<container>"]}},"stability":"deprecated","type":"function"};
41
+ this.sentryDSN.entry = {"args":["project"],"category":"Sentry Credentials","method":"get","name":"sentryDSN","output":true,"query":[],"route":"/sentry/<project>/dsn","scopes":"auth:sentry:<project>","stability":"stable","type":"function"};
42
+ this.websocktunnelToken.entry = {"args":["wstAudience","wstClient"],"category":"Websocktunnel Credentials","method":"get","name":"websocktunnelToken","output":true,"query":[],"route":"/websocktunnel/<wstAudience>/<wstClient>","scopes":"auth:websocktunnel-token:<wstAudience>/<wstClient>","stability":"stable","type":"function"};
43
+ this.gcpCredentials.entry = {"args":["projectId","serviceAccount"],"category":"GCP Credentials","method":"get","name":"gcpCredentials","output":true,"query":[],"route":"/gcp/credentials/<projectId>/<serviceAccount>","scopes":"auth:gcp:access-token:<projectId>/<serviceAccount>","stability":"stable","type":"function"};
44
+ this.authenticateHawk.entry = {"args":[],"category":"Scopes and Auth","input":true,"method":"post","name":"authenticateHawk","output":true,"query":[],"route":"/authenticate-hawk","stability":"stable","type":"function"};
45
+ this.testAuthenticate.entry = {"args":[],"category":"Scopes and Auth","input":true,"method":"post","name":"testAuthenticate","output":true,"query":[],"route":"/test-authenticate","stability":"stable","type":"function"};
46
+ this.testAuthenticateGet.entry = {"args":[],"category":"Scopes and Auth","method":"get","name":"testAuthenticateGet","output":true,"query":[],"route":"/test-authenticate-get/","stability":"stable","type":"function"};
47
+ this.heartbeat.entry = {"args":[],"category":"Monitoring","method":"get","name":"heartbeat","query":[],"route":"/__heartbeat__","stability":"stable","type":"function"};
48
+ }
50
49
  // Respond without doing anything.
51
50
  // This endpoint is used to check that the service is up.
52
- /* eslint-enable max-len */
53
51
  ping(...args) {
54
52
  this.validate(this.ping.entry, args);
55
53
 
56
54
  return this.request(this.ping.entry, args);
57
55
  }
58
- /* eslint-disable max-len */
59
56
  // Respond without doing anything.
60
57
  // This endpoint is used to check that the service is up.
61
- /* eslint-enable max-len */
62
58
  lbheartbeat(...args) {
63
59
  this.validate(this.lbheartbeat.entry, args);
64
60
 
65
61
  return this.request(this.lbheartbeat.entry, args);
66
62
  }
67
- /* eslint-disable max-len */
68
63
  // Respond with the JSON version object.
69
64
  // https://github.com/mozilla-services/Dockerflow/blob/main/docs/version_object.md
70
- /* eslint-enable max-len */
71
65
  version(...args) {
72
66
  this.validate(this.version.entry, args);
73
67
 
74
68
  return this.request(this.version.entry, args);
75
69
  }
76
- /* eslint-disable max-len */
77
70
  // Get a list of all clients. With `prefix`, only clients for which
78
71
  // it is a prefix of the clientId are returned.
79
72
  // By default this end-point will try to return up to 1000 clients in one
@@ -82,21 +75,17 @@ export default class Auth extends Client {
82
75
  // results. However, you can only be sure to have seen all results if you
83
76
  // keep calling `listClients` with the last `continuationToken` until you
84
77
  // get a result without a `continuationToken`.
85
- /* eslint-enable max-len */
86
78
  listClients(...args) {
87
79
  this.validate(this.listClients.entry, args);
88
80
 
89
81
  return this.request(this.listClients.entry, args);
90
82
  }
91
- /* eslint-disable max-len */
92
83
  // Get information about a single client.
93
- /* eslint-enable max-len */
94
84
  client(...args) {
95
85
  this.validate(this.client.entry, args);
96
86
 
97
87
  return this.request(this.client.entry, args);
98
88
  }
99
- /* eslint-disable max-len */
100
89
  // Create a new client and get the `accessToken` for this client.
101
90
  // You should store the `accessToken` from this API call as there is no
102
91
  // other way to retrieve it.
@@ -106,180 +95,146 @@ export default class Auth extends Client {
106
95
  // If a client with the same `clientId` already exists this operation will
107
96
  // fail. Use `updateClient` if you wish to update an existing client.
108
97
  // The caller's scopes must satisfy `scopes`.
109
- /* eslint-enable max-len */
110
98
  createClient(...args) {
111
99
  this.validate(this.createClient.entry, args);
112
100
 
113
101
  return this.request(this.createClient.entry, args);
114
102
  }
115
- /* eslint-disable max-len */
116
103
  // Get entity history based on entity type and entity name
117
- /* eslint-enable max-len */
118
104
  getEntityHistory(...args) {
119
105
  this.validate(this.getEntityHistory.entry, args);
120
106
 
121
107
  return this.request(this.getEntityHistory.entry, args);
122
108
  }
123
- /* eslint-disable max-len */
124
109
  // Get audit history of a client based on clientId.
125
- /* eslint-enable max-len */
126
110
  listAuditHistory(...args) {
127
111
  this.validate(this.listAuditHistory.entry, args);
128
112
 
129
113
  return this.request(this.listAuditHistory.entry, args);
130
114
  }
131
- /* eslint-disable max-len */
132
115
  // Reset a clients `accessToken`, this will revoke the existing
133
116
  // `accessToken`, generate a new `accessToken` and return it from this
134
117
  // call.
135
118
  // There is no way to retrieve an existing `accessToken`, so if you lose it
136
119
  // you must reset the accessToken to acquire it again.
137
- /* eslint-enable max-len */
138
120
  resetAccessToken(...args) {
139
121
  this.validate(this.resetAccessToken.entry, args);
140
122
 
141
123
  return this.request(this.resetAccessToken.entry, args);
142
124
  }
143
- /* eslint-disable max-len */
144
125
  // Update an exisiting client. The `clientId` and `accessToken` cannot be
145
126
  // updated, but `scopes` can be modified. The caller's scopes must
146
127
  // satisfy all scopes being added to the client in the update operation.
147
128
  // If no scopes are given in the request, the client's scopes remain
148
129
  // unchanged
149
- /* eslint-enable max-len */
150
130
  updateClient(...args) {
151
131
  this.validate(this.updateClient.entry, args);
152
132
 
153
133
  return this.request(this.updateClient.entry, args);
154
134
  }
155
- /* eslint-disable max-len */
156
135
  // Enable a client that was disabled with `disableClient`. If the client
157
136
  // is already enabled, this does nothing.
158
137
  // This is typically used by identity providers to re-enable clients that
159
138
  // had been disabled when the corresponding identity's scopes changed.
160
- /* eslint-enable max-len */
161
139
  enableClient(...args) {
162
140
  this.validate(this.enableClient.entry, args);
163
141
 
164
142
  return this.request(this.enableClient.entry, args);
165
143
  }
166
- /* eslint-disable max-len */
167
144
  // Disable a client. If the client is already disabled, this does nothing.
168
145
  // This is typically used by identity providers to disable clients when the
169
146
  // corresponding identity's scopes no longer satisfy the client's scopes.
170
- /* eslint-enable max-len */
171
147
  disableClient(...args) {
172
148
  this.validate(this.disableClient.entry, args);
173
149
 
174
150
  return this.request(this.disableClient.entry, args);
175
151
  }
176
- /* eslint-disable max-len */
177
152
  // Delete a client, please note that any roles related to this client must
178
153
  // be deleted independently.
179
- /* eslint-enable max-len */
180
154
  deleteClient(...args) {
181
155
  this.validate(this.deleteClient.entry, args);
182
156
 
183
157
  return this.request(this.deleteClient.entry, args);
184
158
  }
185
- /* eslint-disable max-len */
186
159
  // Get a list of all roles. Each role object also includes the list of
187
160
  // scopes it expands to. This always returns all roles in a single HTTP
188
161
  // request.
189
162
  // To get paginated results, use `listRoles2`.
190
- /* eslint-enable max-len */
191
163
  listRoles(...args) {
192
164
  this.validate(this.listRoles.entry, args);
193
165
 
194
166
  return this.request(this.listRoles.entry, args);
195
167
  }
196
- /* eslint-disable max-len */
197
168
  // Get a list of all roles. Each role object also includes the list of
198
169
  // scopes it expands to. This is similar to `listRoles` but differs in the
199
170
  // format of the response.
200
171
  // If no limit is given, all roles are returned. Since this
201
172
  // list may become long, callers can use the `limit` and `continuationToken`
202
173
  // query arguments to page through the responses.
203
- /* eslint-enable max-len */
204
174
  listRoles2(...args) {
205
175
  this.validate(this.listRoles2.entry, args);
206
176
 
207
177
  return this.request(this.listRoles2.entry, args);
208
178
  }
209
- /* eslint-disable max-len */
210
179
  // Get a list of all role IDs.
211
180
  // If no limit is given, the roleIds of all roles are returned. Since this
212
181
  // list may become long, callers can use the `limit` and `continuationToken`
213
182
  // query arguments to page through the responses.
214
- /* eslint-enable max-len */
215
183
  listRoleIds(...args) {
216
184
  this.validate(this.listRoleIds.entry, args);
217
185
 
218
186
  return this.request(this.listRoleIds.entry, args);
219
187
  }
220
- /* eslint-disable max-len */
221
188
  // Get information about a single role, including the set of scopes that the
222
189
  // role expands to.
223
- /* eslint-enable max-len */
224
190
  role(...args) {
225
191
  this.validate(this.role.entry, args);
226
192
 
227
193
  return this.request(this.role.entry, args);
228
194
  }
229
- /* eslint-disable max-len */
230
195
  // Create a new role.
231
196
  // The caller's scopes must satisfy the new role's scopes.
232
197
  // If there already exists a role with the same `roleId` this operation
233
198
  // will fail. Use `updateRole` to modify an existing role.
234
199
  // Creation of a role that will generate an infinite expansion will result
235
200
  // in an error response.
236
- /* eslint-enable max-len */
237
201
  createRole(...args) {
238
202
  this.validate(this.createRole.entry, args);
239
203
 
240
204
  return this.request(this.createRole.entry, args);
241
205
  }
242
- /* eslint-disable max-len */
243
206
  // Update an existing role.
244
207
  // The caller's scopes must satisfy all of the new scopes being added, but
245
208
  // need not satisfy all of the role's existing scopes.
246
209
  // An update of a role that will generate an infinite expansion will result
247
210
  // in an error response.
248
- /* eslint-enable max-len */
249
211
  updateRole(...args) {
250
212
  this.validate(this.updateRole.entry, args);
251
213
 
252
214
  return this.request(this.updateRole.entry, args);
253
215
  }
254
- /* eslint-disable max-len */
255
216
  // Delete a role. This operation will succeed regardless of whether or not
256
217
  // the role exists.
257
- /* eslint-enable max-len */
258
218
  deleteRole(...args) {
259
219
  this.validate(this.deleteRole.entry, args);
260
220
 
261
221
  return this.request(this.deleteRole.entry, args);
262
222
  }
263
- /* eslint-disable max-len */
264
223
  // Return an expanded copy of the given scopeset, with scopes implied by any
265
224
  // roles included.
266
- /* eslint-enable max-len */
267
225
  expandScopes(...args) {
268
226
  this.validate(this.expandScopes.entry, args);
269
227
 
270
228
  return this.request(this.expandScopes.entry, args);
271
229
  }
272
- /* eslint-disable max-len */
273
230
  // Return the expanded scopes available in the request, taking into account all sources
274
231
  // of scopes and scope restrictions (temporary credentials, assumeScopes, client scopes,
275
232
  // and roles).
276
- /* eslint-enable max-len */
277
233
  currentScopes(...args) {
278
234
  this.validate(this.currentScopes.entry, args);
279
235
 
280
236
  return this.request(this.currentScopes.entry, args);
281
237
  }
282
- /* eslint-disable max-len */
283
238
  // Get temporary AWS credentials for `read-write` or `read-only` access to
284
239
  // a given `bucket` and `prefix` within that bucket.
285
240
  // The `level` parameter can be `read-write` or `read-only` and determines
@@ -310,74 +265,60 @@ export default class Auth extends Client {
310
265
  // compatibility for libraries and tools built to auto-refresh credentials.
311
266
  // For details on the format returned by EC2 metadata service see:
312
267
  // [EC2 User Guide](http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html#instance-metadata-security-credentials).
313
- /* eslint-enable max-len */
314
268
  awsS3Credentials(...args) {
315
269
  this.validate(this.awsS3Credentials.entry, args);
316
270
 
317
271
  return this.request(this.awsS3Credentials.entry, args);
318
272
  }
319
- /* eslint-disable max-len */
320
273
  // Retrieve a list of all Azure accounts managed by Taskcluster Auth.
321
- /* eslint-enable max-len */
322
274
  azureAccounts(...args) {
323
275
  this.validate(this.azureAccounts.entry, args);
324
276
 
325
277
  return this.request(this.azureAccounts.entry, args);
326
278
  }
327
- /* eslint-disable max-len */
328
279
  // Retrieve a list of all tables in an account.
329
- /* eslint-enable max-len */
330
280
  azureTables(...args) {
331
281
  this.validate(this.azureTables.entry, args);
332
282
 
333
283
  return this.request(this.azureTables.entry, args);
334
284
  }
335
- /* eslint-disable max-len */
336
285
  // Get a shared access signature (SAS) string for use with a specific Azure
337
286
  // Table Storage table.
338
287
  // The `level` parameter can be `read-write` or `read-only` and determines
339
288
  // which type of credentials are returned. If level is read-write, it will create the
340
289
  // table if it doesn't already exist.
341
- /* eslint-enable max-len */
342
290
  azureTableSAS(...args) {
343
291
  this.validate(this.azureTableSAS.entry, args);
344
292
 
345
293
  return this.request(this.azureTableSAS.entry, args);
346
294
  }
347
- /* eslint-disable max-len */
348
295
  // Retrieve a list of all containers in an account.
349
- /* eslint-enable max-len */
350
296
  azureContainers(...args) {
351
297
  this.validate(this.azureContainers.entry, args);
352
298
 
353
299
  return this.request(this.azureContainers.entry, args);
354
300
  }
355
- /* eslint-disable max-len */
356
301
  // Get a shared access signature (SAS) string for use with a specific Azure
357
302
  // Blob Storage container.
358
303
  // The `level` parameter can be `read-write` or `read-only` and determines
359
304
  // which type of credentials are returned. If level is read-write, it will create the
360
305
  // container if it doesn't already exist.
361
- /* eslint-enable max-len */
362
306
  azureContainerSAS(...args) {
363
307
  this.validate(this.azureContainerSAS.entry, args);
364
308
 
365
309
  return this.request(this.azureContainerSAS.entry, args);
366
310
  }
367
- /* eslint-disable max-len */
368
311
  // Get temporary DSN (access credentials) for a sentry project.
369
312
  // The credentials returned can be used with any Sentry client for up to
370
313
  // 24 hours, after which the credentials will be automatically disabled.
371
314
  // If the project doesn't exist it will be created, and assigned to the
372
315
  // initial team configured for this component. Contact a Sentry admin
373
316
  // to have the project transferred to a team you have access to if needed
374
- /* eslint-enable max-len */
375
317
  sentryDSN(...args) {
376
318
  this.validate(this.sentryDSN.entry, args);
377
319
 
378
320
  return this.request(this.sentryDSN.entry, args);
379
321
  }
380
- /* eslint-disable max-len */
381
322
  // Get a temporary token suitable for use connecting to a
382
323
  // [websocktunnel](https://github.com/taskcluster/taskcluster/tree/main/tools/websocktunnel) server.
383
324
  // The resulting token will only be accepted by servers with a matching audience
@@ -386,13 +327,11 @@ export default class Auth extends Client {
386
327
  // along with the audience value.
387
328
  // The token is valid for a limited time (on the scale of hours). Callers should
388
329
  // refresh it before expiration.
389
- /* eslint-enable max-len */
390
330
  websocktunnelToken(...args) {
391
331
  this.validate(this.websocktunnelToken.entry, args);
392
332
 
393
333
  return this.request(this.websocktunnelToken.entry, args);
394
334
  }
395
- /* eslint-disable max-len */
396
335
  // Get temporary GCP credentials for the given serviceAccount in the given project.
397
336
  // Only preconfigured projects and serviceAccounts are allowed, as defined in the
398
337
  // deployment of the Taskcluster services.
@@ -400,25 +339,21 @@ export default class Auth extends Client {
400
339
  // subject to change. Hence, you should always read the `expires` property
401
340
  // from the response, if you intend to maintain active credentials in your
402
341
  // application.
403
- /* eslint-enable max-len */
404
342
  gcpCredentials(...args) {
405
343
  this.validate(this.gcpCredentials.entry, args);
406
344
 
407
345
  return this.request(this.gcpCredentials.entry, args);
408
346
  }
409
- /* eslint-disable max-len */
410
347
  // Validate the request signature given on input and return list of scopes
411
348
  // that the authenticating client has.
412
349
  // This method is used by other services that wish rely on Taskcluster
413
350
  // credentials for authentication. This way we can use Hawk without having
414
351
  // the secret credentials leave this service.
415
- /* eslint-enable max-len */
416
352
  authenticateHawk(...args) {
417
353
  this.validate(this.authenticateHawk.entry, args);
418
354
 
419
355
  return this.request(this.authenticateHawk.entry, args);
420
356
  }
421
- /* eslint-disable max-len */
422
357
  // Utility method to test client implementations of Taskcluster
423
358
  // authentication.
424
359
  // Rather than using real credentials, this endpoint accepts requests with
@@ -428,13 +363,11 @@ export default class Auth extends Client {
428
363
  // applied, and the resulting scopes are checked against `requiredScopes`
429
364
  // from the request body. On success, the response contains the clientId
430
365
  // and scopes as seen by the API method.
431
- /* eslint-enable max-len */
432
366
  testAuthenticate(...args) {
433
367
  this.validate(this.testAuthenticate.entry, args);
434
368
 
435
369
  return this.request(this.testAuthenticate.entry, args);
436
370
  }
437
- /* eslint-disable max-len */
438
371
  // Utility method similar to `testAuthenticate`, but with the GET method,
439
372
  // so it can be used with signed URLs (bewits).
440
373
  // Rather than using real credentials, this endpoint accepts requests with
@@ -447,17 +380,14 @@ export default class Auth extends Client {
447
380
  // the API method.
448
381
  // This method may later be extended to allow specification of client and
449
382
  // required scopes via query arguments.
450
- /* eslint-enable max-len */
451
383
  testAuthenticateGet(...args) {
452
384
  this.validate(this.testAuthenticateGet.entry, args);
453
385
 
454
386
  return this.request(this.testAuthenticateGet.entry, args);
455
387
  }
456
- /* eslint-disable max-len */
457
388
  // Respond with a service heartbeat.
458
389
  // This endpoint is used to check on backing services this service
459
390
  // depends on.
460
- /* eslint-enable max-len */
461
391
  heartbeat(...args) {
462
392
  this.validate(this.heartbeat.entry, args);
463
393
 
@@ -11,51 +11,39 @@ export default class AuthEvents extends Client {
11
11
  ...options,
12
12
  });
13
13
  }
14
- /* eslint-disable max-len */
15
14
  // Message that a new client has been created.
16
- /* eslint-enable max-len */
17
15
  clientCreated(pattern) {
18
- const entry = {"exchange":"client-created","name":"clientCreated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/client-message.json#","type":"topic-exchange"}; // eslint-disable-line
16
+ const entry = {"exchange":"client-created","name":"clientCreated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/client-message.json#","type":"topic-exchange"};
19
17
 
20
18
  return this.normalizePattern(entry, pattern);
21
19
  }
22
- /* eslint-disable max-len */
23
20
  // Message that a new client has been updated.
24
- /* eslint-enable max-len */
25
21
  clientUpdated(pattern) {
26
- const entry = {"exchange":"client-updated","name":"clientUpdated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/client-message.json#","type":"topic-exchange"}; // eslint-disable-line
22
+ const entry = {"exchange":"client-updated","name":"clientUpdated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/client-message.json#","type":"topic-exchange"};
27
23
 
28
24
  return this.normalizePattern(entry, pattern);
29
25
  }
30
- /* eslint-disable max-len */
31
26
  // Message that a new client has been deleted.
32
- /* eslint-enable max-len */
33
27
  clientDeleted(pattern) {
34
- const entry = {"exchange":"client-deleted","name":"clientDeleted","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/client-message.json#","type":"topic-exchange"}; // eslint-disable-line
28
+ const entry = {"exchange":"client-deleted","name":"clientDeleted","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/client-message.json#","type":"topic-exchange"};
35
29
 
36
30
  return this.normalizePattern(entry, pattern);
37
31
  }
38
- /* eslint-disable max-len */
39
32
  // Message that a new role has been created.
40
- /* eslint-enable max-len */
41
33
  roleCreated(pattern) {
42
- const entry = {"exchange":"role-created","name":"roleCreated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/role-message.json#","type":"topic-exchange"}; // eslint-disable-line
34
+ const entry = {"exchange":"role-created","name":"roleCreated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/role-message.json#","type":"topic-exchange"};
43
35
 
44
36
  return this.normalizePattern(entry, pattern);
45
37
  }
46
- /* eslint-disable max-len */
47
38
  // Message that a new role has been updated.
48
- /* eslint-enable max-len */
49
39
  roleUpdated(pattern) {
50
- const entry = {"exchange":"role-updated","name":"roleUpdated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/role-message.json#","type":"topic-exchange"}; // eslint-disable-line
40
+ const entry = {"exchange":"role-updated","name":"roleUpdated","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/role-message.json#","type":"topic-exchange"};
51
41
 
52
42
  return this.normalizePattern(entry, pattern);
53
43
  }
54
- /* eslint-disable max-len */
55
44
  // Message that a new role has been deleted.
56
- /* eslint-enable max-len */
57
45
  roleDeleted(pattern) {
58
- const entry = {"exchange":"role-deleted","name":"roleDeleted","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/role-message.json#","type":"topic-exchange"}; // eslint-disable-line
46
+ const entry = {"exchange":"role-deleted","name":"roleDeleted","routingKey":[{"multipleWords":true,"name":"reserved","required":false}],"schema":"v1/role-message.json#","type":"topic-exchange"};
59
47
 
60
48
  return this.normalizePattern(entry, pattern);
61
49
  }