asana 0.10.3 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/build.yml +24 -0
  3. data/.github/workflows/pubilsh-to-rubygem.yml +18 -0
  4. data/.github/workflows/publish-to-github-releases.yml +16 -0
  5. data/.gitignore +0 -1
  6. data/.ruby-version +1 -1
  7. data/Gemfile.lock +174 -0
  8. data/README.md +22 -9
  9. data/Rakefile +10 -14
  10. data/VERSION +1 -1
  11. data/asana.gemspec +3 -3
  12. data/examples/Gemfile.lock +2 -2
  13. data/lib/asana/http_client/error_handling.rb +11 -4
  14. data/lib/asana/resources/gen/attachments_base.rb +7 -6
  15. data/lib/asana/resources/gen/audit_log_api_base.rb +37 -0
  16. data/lib/asana/resources/gen/goals_base.rb +229 -0
  17. data/lib/asana/resources/gen/project_briefs_base.rb +68 -0
  18. data/lib/asana/resources/gen/project_templates_base.rb +73 -0
  19. data/lib/asana/resources/gen/projects_base.rb +13 -0
  20. data/lib/asana/resources/gen/status_updates_base.rb +72 -0
  21. data/lib/asana/resources/gen/tasks_base.rb +7 -9
  22. data/lib/asana/resources/gen/teams_base.rb +27 -13
  23. data/lib/asana/resources/gen/time_periods_base.rb +47 -0
  24. data/lib/asana/resources/gen/typeahead_base.rb +1 -1
  25. data/lib/asana/resources/gen/users_base.rb +3 -4
  26. data/lib/asana/resources/gen/webhooks_base.rb +13 -0
  27. data/lib/asana/resources/gen/workspaces_base.rb +1 -1
  28. data/lib/asana/resources/portfolio.rb +3 -3
  29. data/lib/asana/version.rb +1 -1
  30. data/package-lock.json +115 -0
  31. data/samples/attachments_sample.yaml +3 -3
  32. data/samples/audit_log_api_sample.yaml +11 -0
  33. data/samples/goals_sample.yaml +161 -0
  34. data/samples/project_briefs_sample.yaml +41 -0
  35. data/samples/project_templates_sample.yaml +41 -0
  36. data/samples/projects_sample.yaml +10 -0
  37. data/samples/status_updates_sample.yaml +41 -0
  38. data/samples/teams_sample.yaml +14 -4
  39. data/samples/time_periods_sample.yaml +21 -0
  40. data/samples/webhooks_sample.yaml +10 -0
  41. metadata +36 -14
  42. data/.travis.yml +0 -16
@@ -22,35 +22,35 @@ module Asana
22
22
  def add_user_for_team(client, team_gid: required("team_gid"), options: {}, **data)
23
23
  path = "/teams/{team_gid}/addUser"
24
24
  path["{team_gid}"] = team_gid
25
- User.new(parse(client.post(path, body: data, options: options)).first, client: client)
25
+ parse(client.post(path, body: data, options: options)).first
26
26
  end
27
27
 
28
- # Get a team
28
+ # Create a team
29
29
  #
30
- # team_gid - [str] (required) Globally unique identifier for the team.
30
+
31
31
  # options - [Hash] the request I/O options
32
32
  # > offset - [str] Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.'
33
33
  # > limit - [int] Results per page. The number of objects to return per page. The value must be between 1 and 100.
34
34
  # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
35
35
  # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
36
- def get_team(client, team_gid: required("team_gid"), options: {})
37
- path = "/teams/{team_gid}"
38
- path["{team_gid}"] = team_gid
39
- Team.new(parse(client.get(path, options: options)).first, client: client)
36
+ # data - [Hash] the attributes to POST
37
+ def create_team(client, options: {}, **data)
38
+ path = "/teams"
39
+ Team.new(parse(client.post(path, body: data, options: options)).first, client: client)
40
40
  end
41
41
 
42
- # Get teams in an organization
42
+ # Get a team
43
43
  #
44
- # workspace_gid - [str] (required) Globally unique identifier for the workspace or organization.
44
+ # team_gid - [str] (required) Globally unique identifier for the team.
45
45
  # options - [Hash] the request I/O options
46
46
  # > offset - [str] Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.'
47
47
  # > limit - [int] Results per page. The number of objects to return per page. The value must be between 1 and 100.
48
48
  # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
49
49
  # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
50
- def get_teams_for_organization(client, workspace_gid: required("workspace_gid"), options: {})
51
- path = "/organizations/{workspace_gid}/teams"
52
- path["{workspace_gid}"] = workspace_gid
53
- Collection.new(parse(client.get(path, options: options)), type: Team, client: client)
50
+ def get_team(client, team_gid: required("team_gid"), options: {})
51
+ path = "/teams/{team_gid}"
52
+ path["{team_gid}"] = team_gid
53
+ Team.new(parse(client.get(path, options: options)).first, client: client)
54
54
  end
55
55
 
56
56
  # Get teams for a user
@@ -69,6 +69,20 @@ module Asana
69
69
  Collection.new(parse(client.get(path, params: params, options: options)), type: Team, client: client)
70
70
  end
71
71
 
72
+ # Get teams in a workspace
73
+ #
74
+ # workspace_gid - [str] (required) Globally unique identifier for the workspace or organization.
75
+ # options - [Hash] the request I/O options
76
+ # > offset - [str] Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.'
77
+ # > limit - [int] Results per page. The number of objects to return per page. The value must be between 1 and 100.
78
+ # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
79
+ # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
80
+ def get_teams_for_workspace(client, workspace_gid: required("workspace_gid"), options: {})
81
+ path = "/workspaces/{workspace_gid}/teams"
82
+ path["{workspace_gid}"] = workspace_gid
83
+ Collection.new(parse(client.get(path, options: options)), type: Team, client: client)
84
+ end
85
+
72
86
  # Remove a user from a team
73
87
  #
74
88
  # team_gid - [str] (required) Globally unique identifier for the team.
@@ -0,0 +1,47 @@
1
+ ### WARNING: This file is auto-generated by our OpenAPI spec. Do not
2
+ ### edit it manually.
3
+
4
+ require_relative '../../resource_includes/response_helper'
5
+
6
+ module Asana
7
+ module Resources
8
+ class TimePeriodsBase < Resource
9
+
10
+ def self.inherited(base)
11
+ Registry.register(base)
12
+ end
13
+
14
+ class << self
15
+ # Get a time period
16
+ #
17
+ # time_period_gid - [str] (required) Globally unique identifier for the time period.
18
+ # options - [Hash] the request I/O options
19
+ # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
20
+ # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
21
+ def get_time_period(client, time_period_gid: required("time_period_gid"), options: {})
22
+ path = "/time_periods/{time_period_gid}"
23
+ path["{time_period_gid}"] = time_period_gid
24
+ parse(client.get(path, options: options)).first
25
+ end
26
+
27
+ # Get time periods
28
+ #
29
+
30
+ # start_on - [date] ISO 8601 date string
31
+ # end_on - [date] ISO 8601 date string
32
+ # workspace - [str] (required) Globally unique identifier for the workspace.
33
+ # options - [Hash] the request I/O options
34
+ # > offset - [str] Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.'
35
+ # > limit - [int] Results per page. The number of objects to return per page. The value must be between 1 and 100.
36
+ # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
37
+ # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
38
+ def get_time_periods(client, start_on: nil, end_on: nil, workspace: nil, options: {})
39
+ path = "/time_periods"
40
+ params = { start_on: start_on, end_on: end_on, workspace: workspace }.reject { |_,v| v.nil? || Array(v).empty? }
41
+ Collection.new(parse(client.get(path, params: params, options: options)), type: Resource, client: client)
42
+ end
43
+
44
+ end
45
+ end
46
+ end
47
+ end
@@ -15,7 +15,7 @@ module Asana
15
15
  # Get objects via typeahead
16
16
  #
17
17
  # workspace_gid - [str] (required) Globally unique identifier for the workspace or organization.
18
- # resource_type - [str] (required) The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported.
18
+ # resource_type - [str] (required) The type of values the typeahead should return. You can choose from one of the following: `custom_field`, `project`, `project_template`, `portfolio`, `tag`, `task`, and `user`. Note that unlike in the names of endpoints, the types listed here are in singular form (e.g. `task`). Using multiple types is not yet supported.
19
19
  # type - [str] *Deprecated: new integrations should prefer the resource_type field.*
20
20
  # query - [str] The string that will be used to search for relevant objects. If an empty string is passed in, the API will currently return an empty result set.
21
21
  # count - [int] The number of results to return. The default is 20 if this parameter is omitted, with a minimum of 1 and a maximum of 100. If there are fewer results found than requested, all will be returned.
@@ -43,14 +43,15 @@ module Asana
43
43
  #
44
44
 
45
45
  # workspace - [str] The workspace or organization ID to filter users on.
46
+ # team - [str] The team ID to filter users on.
46
47
  # options - [Hash] the request I/O options
47
48
  # > offset - [str] Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.'
48
49
  # > limit - [int] Results per page. The number of objects to return per page. The value must be between 1 and 100.
49
50
  # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
50
51
  # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
51
- def get_users(client, workspace: nil, options: {})
52
+ def get_users(client, workspace: nil, team: nil, options: {})
52
53
  path = "/users"
53
- params = { workspace: workspace }.reject { |_,v| v.nil? || Array(v).empty? }
54
+ params = { workspace: workspace, team: team }.reject { |_,v| v.nil? || Array(v).empty? }
54
55
  Collection.new(parse(client.get(path, params: params, options: options)), type: User, client: client)
55
56
  end
56
57
 
@@ -59,7 +60,6 @@ module Asana
59
60
  # team_gid - [str] (required) Globally unique identifier for the team.
60
61
  # options - [Hash] the request I/O options
61
62
  # > offset - [str] Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.'
62
- # > limit - [int] Results per page. The number of objects to return per page. The value must be between 1 and 100.
63
63
  # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
64
64
  # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
65
65
  def get_users_for_team(client, team_gid: required("team_gid"), options: {})
@@ -73,7 +73,6 @@ module Asana
73
73
  # workspace_gid - [str] (required) Globally unique identifier for the workspace or organization.
74
74
  # options - [Hash] the request I/O options
75
75
  # > offset - [str] Offset token. An offset to the next page returned by the API. A pagination request will return an offset token, which can be used as an input parameter to the next request. If an offset is not passed in, the API will return the first page of results. 'Note: You can only pass in an offset that was returned to you via a previously paginated request.'
76
- # > limit - [int] Results per page. The number of objects to return per page. The value must be between 1 and 100.
77
76
  # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
78
77
  # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
79
78
  def get_users_for_workspace(client, workspace_gid: required("workspace_gid"), options: {})
@@ -64,6 +64,19 @@ module Asana
64
64
  Collection.new(parse(client.get(path, params: params, options: options)), type: Webhook, client: client)
65
65
  end
66
66
 
67
+ # Update a webhook
68
+ #
69
+ # webhook_gid - [str] (required) Globally unique identifier for the webhook.
70
+ # options - [Hash] the request I/O options
71
+ # > opt_fields - [list[str]] Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
72
+ # > opt_pretty - [bool] Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
73
+ # data - [Hash] the attributes to PUT
74
+ def update_webhook(client, webhook_gid: required("webhook_gid"), options: {}, **data)
75
+ path = "/webhooks/{webhook_gid}"
76
+ path["{webhook_gid}"] = webhook_gid
77
+ Webhook.new(parse(client.put(path, body: data, options: options)).first, client: client)
78
+ end
79
+
67
80
  end
68
81
  end
69
82
  end
@@ -22,7 +22,7 @@ module Asana
22
22
  def add_user_for_workspace(client, workspace_gid: required("workspace_gid"), options: {}, **data)
23
23
  path = "/workspaces/{workspace_gid}/addUser"
24
24
  path["{workspace_gid}"] = workspace_gid
25
- User.new(parse(client.post(path, body: data, options: options)).first, client: client)
25
+ parse(client.post(path, body: data, options: options)).first
26
26
  end
27
27
 
28
28
  # Get a workspace
@@ -107,7 +107,7 @@ module Asana
107
107
  # options - [Hash] the request I/O options.
108
108
  def get_items(options: {})
109
109
 
110
- Collection.new(parse(client.get("/portfolios/#{gid}/items", options: options)), type: self, client: client)
110
+ Collection.new(parse(client.get("/portfolios/#{gid}/items", options: options)), type: Resource, client: client)
111
111
  end
112
112
 
113
113
  # Add an item to a portfolio.
@@ -165,7 +165,7 @@ module Asana
165
165
  # options - [Hash] the request I/O options.
166
166
  def custom_field_settings(options: {})
167
167
 
168
- Collection.new(parse(client.get("/portfolios/#{gid}/custom_field_settings", options: options)), type: self, client: client)
168
+ Collection.new(parse(client.get("/portfolios/#{gid}/custom_field_settings", options: options)), type: CustomFieldSetting, client: client)
169
169
  end
170
170
 
171
171
  # Create a new custom field setting on the portfolio. Returns the full
@@ -200,4 +200,4 @@ module Asana
200
200
 
201
201
  end
202
202
  end
203
- end
203
+ end
data/lib/asana/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  #:nodoc:
2
2
  module Asana
3
3
  # Public: Version of the gem.
4
- VERSION = '0.10.3'
4
+ VERSION = '1.0.0'
5
5
  end
data/package-lock.json ADDED
@@ -0,0 +1,115 @@
1
+ {
2
+ "name": "ruby-asana",
3
+ "lockfileVersion": 2,
4
+ "requires": true,
5
+ "packages": {
6
+ "": {
7
+ "devDependencies": {
8
+ "inflect": "^0.3.0",
9
+ "js-yaml": "^3.2.5",
10
+ "lodash": "^4.17.13"
11
+ }
12
+ },
13
+ "node_modules/argparse": {
14
+ "version": "1.0.10",
15
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz",
16
+ "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==",
17
+ "dev": true,
18
+ "dependencies": {
19
+ "sprintf-js": "~1.0.2"
20
+ }
21
+ },
22
+ "node_modules/esprima": {
23
+ "version": "4.0.1",
24
+ "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz",
25
+ "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==",
26
+ "dev": true,
27
+ "bin": {
28
+ "esparse": "bin/esparse.js",
29
+ "esvalidate": "bin/esvalidate.js"
30
+ },
31
+ "engines": {
32
+ "node": ">=4"
33
+ }
34
+ },
35
+ "node_modules/inflect": {
36
+ "version": "0.3.0",
37
+ "resolved": "https://registry.npmjs.org/inflect/-/inflect-0.3.0.tgz",
38
+ "integrity": "sha1-gdDqqja1CmAjC3UQBIs5xBQv5So=",
39
+ "dev": true,
40
+ "engines": {
41
+ "node": ">=0.4"
42
+ }
43
+ },
44
+ "node_modules/js-yaml": {
45
+ "version": "3.14.1",
46
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz",
47
+ "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==",
48
+ "dev": true,
49
+ "dependencies": {
50
+ "argparse": "^1.0.7",
51
+ "esprima": "^4.0.0"
52
+ },
53
+ "bin": {
54
+ "js-yaml": "bin/js-yaml.js"
55
+ }
56
+ },
57
+ "node_modules/lodash": {
58
+ "version": "4.17.21",
59
+ "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
60
+ "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
61
+ "dev": true
62
+ },
63
+ "node_modules/sprintf-js": {
64
+ "version": "1.0.3",
65
+ "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz",
66
+ "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=",
67
+ "dev": true
68
+ }
69
+ },
70
+ "dependencies": {
71
+ "argparse": {
72
+ "version": "1.0.10",
73
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz",
74
+ "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==",
75
+ "dev": true,
76
+ "requires": {
77
+ "sprintf-js": "~1.0.2"
78
+ }
79
+ },
80
+ "esprima": {
81
+ "version": "4.0.1",
82
+ "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz",
83
+ "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==",
84
+ "dev": true
85
+ },
86
+ "inflect": {
87
+ "version": "0.3.0",
88
+ "resolved": "https://registry.npmjs.org/inflect/-/inflect-0.3.0.tgz",
89
+ "integrity": "sha1-gdDqqja1CmAjC3UQBIs5xBQv5So=",
90
+ "dev": true
91
+ },
92
+ "js-yaml": {
93
+ "version": "3.14.1",
94
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz",
95
+ "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==",
96
+ "dev": true,
97
+ "requires": {
98
+ "argparse": "^1.0.7",
99
+ "esprima": "^4.0.0"
100
+ }
101
+ },
102
+ "lodash": {
103
+ "version": "4.17.21",
104
+ "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
105
+ "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
106
+ "dev": true
107
+ },
108
+ "sprintf-js": {
109
+ "version": "1.0.3",
110
+ "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz",
111
+ "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=",
112
+ "dev": true
113
+ }
114
+ }
115
+ }
@@ -8,7 +8,7 @@ attachments:
8
8
  end
9
9
 
10
10
 
11
- result = client.attachments.create_attachment_for_task(task_gid: 'task_gid', field: "value", field: "value", options: {pretty: true})
11
+ result = client.attachments.create_attachment_for_task(field: "value", field: "value", options: {pretty: true})
12
12
  delete_attachment: >-
13
13
  require 'asana'
14
14
 
@@ -29,7 +29,7 @@ attachments:
29
29
 
30
30
 
31
31
  result = client.attachments.get_attachment(attachment_gid: 'attachment_gid', param: "value", param: "value", options: {pretty: true})
32
- get_attachments_for_task: >-
32
+ get_attachments_for_object: >-
33
33
  require 'asana'
34
34
 
35
35
 
@@ -38,4 +38,4 @@ attachments:
38
38
  end
39
39
 
40
40
 
41
- result = client.attachments.get_attachments_for_task(task_gid: 'task_gid', param: "value", param: "value", options: {pretty: true})
41
+ result = client.attachments.get_attachments_for_object(parent: '&#x27;parent_example&#x27;', param: "value", param: "value", options: {pretty: true})
@@ -0,0 +1,11 @@
1
+ auditlogapi:
2
+ get_audit_log_events: >-
3
+ require 'asana'
4
+
5
+
6
+ client = Asana::Client.new do |c|
7
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
8
+ end
9
+
10
+
11
+ result = client.audit_log_api.get_audit_log_events(workspace_gid: 'workspace_gid', param: "value", param: "value", options: {pretty: true})
@@ -0,0 +1,161 @@
1
+ goals:
2
+ add_followers: >-
3
+ require 'asana'
4
+
5
+
6
+ client = Asana::Client.new do |c|
7
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
8
+ end
9
+
10
+
11
+ result = client.goals.add_followers(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
12
+ add_subgoal: >-
13
+ require 'asana'
14
+
15
+
16
+ client = Asana::Client.new do |c|
17
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
18
+ end
19
+
20
+
21
+ result = client.goals.add_subgoal(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
22
+ add_supporting_work_for_goal: >-
23
+ require 'asana'
24
+
25
+
26
+ client = Asana::Client.new do |c|
27
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
28
+ end
29
+
30
+
31
+ result = client.goals.add_supporting_work_for_goal(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
32
+ create_goal: >-
33
+ require 'asana'
34
+
35
+
36
+ client = Asana::Client.new do |c|
37
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
38
+ end
39
+
40
+
41
+ result = client.goals.create_goal(field: "value", field: "value", options: {pretty: true})
42
+ create_goal_metric: >-
43
+ require 'asana'
44
+
45
+
46
+ client = Asana::Client.new do |c|
47
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
48
+ end
49
+
50
+
51
+ result = client.goals.create_goal_metric(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
52
+ delete_goal: >-
53
+ require 'asana'
54
+
55
+
56
+ client = Asana::Client.new do |c|
57
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
58
+ end
59
+
60
+
61
+ result = client.goals.delete_goal(goal_gid: 'goal_gid', options: {pretty: true})
62
+ get_goal: >-
63
+ require 'asana'
64
+
65
+
66
+ client = Asana::Client.new do |c|
67
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
68
+ end
69
+
70
+
71
+ result = client.goals.get_goal(goal_gid: 'goal_gid', param: "value", param: "value", options: {pretty: true})
72
+ get_goals: >-
73
+ require 'asana'
74
+
75
+
76
+ client = Asana::Client.new do |c|
77
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
78
+ end
79
+
80
+
81
+ result = client.goals.get_goals(param: "value", param: "value", options: {pretty: true})
82
+ get_parent_goals_for_goal: >-
83
+ require 'asana'
84
+
85
+
86
+ client = Asana::Client.new do |c|
87
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
88
+ end
89
+
90
+
91
+ result = client.goals.get_parent_goals_for_goal(goal_gid: 'goal_gid', param: "value", param: "value", options: {pretty: true})
92
+ get_subgoals_for_goal: >-
93
+ require 'asana'
94
+
95
+
96
+ client = Asana::Client.new do |c|
97
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
98
+ end
99
+
100
+
101
+ result = client.goals.get_subgoals_for_goal(goal_gid: 'goal_gid', param: "value", param: "value", options: {pretty: true})
102
+ remove_followers: >-
103
+ require 'asana'
104
+
105
+
106
+ client = Asana::Client.new do |c|
107
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
108
+ end
109
+
110
+
111
+ result = client.goals.remove_followers(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
112
+ remove_subgoal: >-
113
+ require 'asana'
114
+
115
+
116
+ client = Asana::Client.new do |c|
117
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
118
+ end
119
+
120
+
121
+ result = client.goals.remove_subgoal(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
122
+ remove_supporting_work_for_goal: >-
123
+ require 'asana'
124
+
125
+
126
+ client = Asana::Client.new do |c|
127
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
128
+ end
129
+
130
+
131
+ result = client.goals.remove_supporting_work_for_goal(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
132
+ supporting_work: >-
133
+ require 'asana'
134
+
135
+
136
+ client = Asana::Client.new do |c|
137
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
138
+ end
139
+
140
+
141
+ result = client.goals.supporting_work(goal_gid: 'goal_gid', param: "value", param: "value", options: {pretty: true})
142
+ update_goal: >-
143
+ require 'asana'
144
+
145
+
146
+ client = Asana::Client.new do |c|
147
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
148
+ end
149
+
150
+
151
+ result = client.goals.update_goal(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
152
+ update_goal_metric: >-
153
+ require 'asana'
154
+
155
+
156
+ client = Asana::Client.new do |c|
157
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
158
+ end
159
+
160
+
161
+ result = client.goals.update_goal_metric(goal_gid: 'goal_gid', field: "value", field: "value", options: {pretty: true})
@@ -0,0 +1,41 @@
1
+ projectbriefs:
2
+ create_project_brief: >-
3
+ require 'asana'
4
+
5
+
6
+ client = Asana::Client.new do |c|
7
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
8
+ end
9
+
10
+
11
+ result = client.project_briefs.create_project_brief(project_gid: 'project_gid', field: "value", field: "value", options: {pretty: true})
12
+ delete_project_brief: >-
13
+ require 'asana'
14
+
15
+
16
+ client = Asana::Client.new do |c|
17
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
18
+ end
19
+
20
+
21
+ result = client.project_briefs.delete_project_brief(project_brief_gid: 'project_brief_gid', options: {pretty: true})
22
+ get_project_brief: >-
23
+ require 'asana'
24
+
25
+
26
+ client = Asana::Client.new do |c|
27
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
28
+ end
29
+
30
+
31
+ result = client.project_briefs.get_project_brief(project_brief_gid: 'project_brief_gid', param: "value", param: "value", options: {pretty: true})
32
+ update_project_brief: >-
33
+ require 'asana'
34
+
35
+
36
+ client = Asana::Client.new do |c|
37
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
38
+ end
39
+
40
+
41
+ result = client.project_briefs.update_project_brief(project_brief_gid: 'project_brief_gid', field: "value", field: "value", options: {pretty: true})
@@ -0,0 +1,41 @@
1
+ projecttemplates:
2
+ get_project_template: >-
3
+ require 'asana'
4
+
5
+
6
+ client = Asana::Client.new do |c|
7
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
8
+ end
9
+
10
+
11
+ result = client.project_templates.get_project_template(project_template_gid: 'project_template_gid', param: "value", param: "value", options: {pretty: true})
12
+ get_project_templates: >-
13
+ require 'asana'
14
+
15
+
16
+ client = Asana::Client.new do |c|
17
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
18
+ end
19
+
20
+
21
+ result = client.project_templates.get_project_templates(param: "value", param: "value", options: {pretty: true})
22
+ get_project_templates_for_team: >-
23
+ require 'asana'
24
+
25
+
26
+ client = Asana::Client.new do |c|
27
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
28
+ end
29
+
30
+
31
+ result = client.project_templates.get_project_templates_for_team(team_gid: 'team_gid', param: "value", param: "value", options: {pretty: true})
32
+ instantiate_project: >-
33
+ require 'asana'
34
+
35
+
36
+ client = Asana::Client.new do |c|
37
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
38
+ end
39
+
40
+
41
+ result = client.project_templates.instantiate_project(project_template_gid: 'project_template_gid', field: "value", field: "value", options: {pretty: true})
@@ -139,6 +139,16 @@ projects:
139
139
 
140
140
 
141
141
  result = client.projects.get_task_counts_for_project(project_gid: 'project_gid', param: "value", param: "value", options: {pretty: true})
142
+ project_save_as_template: >-
143
+ require 'asana'
144
+
145
+
146
+ client = Asana::Client.new do |c|
147
+ c.authentication :access_token, 'PERSONAL_ACCESS_TOKEN'
148
+ end
149
+
150
+
151
+ result = client.projects.project_save_as_template(project_gid: 'project_gid', field: "value", field: "value", options: {pretty: true})
142
152
  remove_custom_field_setting_for_project: >-
143
153
  require 'asana'
144
154