smartsheet 1.0.0 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +11 -11
- data/.rubocop.yml +4 -4
- data/.travis.yml +13 -6
- data/.yardopts +3 -3
- data/CHANGELOG.md +103 -0
- data/Gemfile +6 -6
- data/LICENSE +202 -202
- data/README.md +214 -141
- data/Rakefile +29 -23
- data/bin/console +14 -14
- data/bin/setup +8 -8
- data/lib/smartsheet.rb +2 -2
- data/lib/smartsheet/api/body_builder.rb +25 -25
- data/lib/smartsheet/api/endpoint_spec.rb +54 -36
- data/lib/smartsheet/api/faraday_adapter/faraday_net_client.rb +45 -42
- data/lib/smartsheet/api/faraday_adapter/faraday_response.rb +70 -70
- data/lib/smartsheet/api/faraday_adapter/middleware/faraday_error_translator.rb +20 -20
- data/lib/smartsheet/api/faraday_adapter/middleware/response_parser.rb +25 -25
- data/lib/smartsheet/api/file_spec.rb +31 -31
- data/lib/smartsheet/api/header_builder.rb +90 -84
- data/lib/smartsheet/api/request.rb +42 -29
- data/lib/smartsheet/api/request_client.rb +43 -27
- data/lib/smartsheet/api/request_logger.rb +182 -182
- data/lib/smartsheet/api/request_spec.rb +57 -44
- data/lib/smartsheet/api/response_net_client_decorator.rb +54 -54
- data/lib/smartsheet/api/retry_logic.rb +40 -40
- data/lib/smartsheet/api/retry_net_client_decorator.rb +37 -37
- data/lib/smartsheet/api/url_builder.rb +25 -25
- data/lib/smartsheet/client.rb +191 -185
- data/lib/smartsheet/constants.rb +15 -15
- data/lib/smartsheet/endpoints/contacts/contacts.rb +30 -30
- data/lib/smartsheet/endpoints/favorites/favorites.rb +159 -159
- data/lib/smartsheet/endpoints/folders/folders.rb +125 -125
- data/lib/smartsheet/endpoints/groups/groups.rb +83 -83
- data/lib/smartsheet/endpoints/home/home.rb +20 -20
- data/lib/smartsheet/endpoints/reports/reports.rb +100 -100
- data/lib/smartsheet/endpoints/reports/reports_share.rb +69 -69
- data/lib/smartsheet/endpoints/search/search.rb +30 -30
- data/lib/smartsheet/endpoints/server_info/server_info.rb +21 -21
- data/lib/smartsheet/endpoints/share/share.rb +58 -58
- data/lib/smartsheet/endpoints/sheets/automation_rules.rb +56 -0
- data/lib/smartsheet/endpoints/sheets/cells.rb +82 -82
- data/lib/smartsheet/endpoints/sheets/columns.rb +66 -66
- data/lib/smartsheet/endpoints/sheets/comments.rb +64 -64
- data/lib/smartsheet/endpoints/sheets/comments_attachments.rb +78 -78
- data/lib/smartsheet/endpoints/sheets/cross_sheet_references.rb +45 -0
- data/lib/smartsheet/endpoints/sheets/discussions.rb +84 -84
- data/lib/smartsheet/endpoints/sheets/discussions_attachments.rb +22 -22
- data/lib/smartsheet/endpoints/sheets/rows.rb +106 -95
- data/lib/smartsheet/endpoints/sheets/rows_attachments.rb +92 -92
- data/lib/smartsheet/endpoints/sheets/sheets.rb +326 -317
- data/lib/smartsheet/endpoints/sheets/sheets_attachments.rb +174 -174
- data/lib/smartsheet/endpoints/sheets/sheets_share.rb +69 -69
- data/lib/smartsheet/endpoints/sights/sights.rb +101 -101
- data/lib/smartsheet/endpoints/sights/sights_share.rb +69 -69
- data/lib/smartsheet/endpoints/templates/templates.rb +29 -29
- data/lib/smartsheet/endpoints/token/token.rb +65 -60
- data/lib/smartsheet/endpoints/update_requests/sent_update_requests.rb +44 -44
- data/lib/smartsheet/endpoints/update_requests/update_requests.rb +74 -74
- data/lib/smartsheet/endpoints/users/alternate_emails.rb +79 -79
- data/lib/smartsheet/endpoints/users/users.rb +77 -77
- data/lib/smartsheet/endpoints/webhooks/webhooks.rb +71 -71
- data/lib/smartsheet/endpoints/workspaces/workspaces.rb +87 -87
- data/lib/smartsheet/endpoints/workspaces/workspaces_share.rb +70 -70
- data/lib/smartsheet/error.rb +69 -69
- data/lib/smartsheet/general_request.rb +74 -74
- data/lib/smartsheet/version.rb +5 -5
- data/smartsheet.gemspec +54 -52
- metadata +34 -3
@@ -1,23 +1,23 @@
|
|
1
|
-
module Smartsheet
|
2
|
-
# Discussions Attachments Endpoints
|
3
|
-
# @see https://smartsheet-platform.github.io/api-docs/?ruby#attachments API Attachments Docs
|
4
|
-
class DiscussionsAttachments
|
5
|
-
attr_reader :client
|
6
|
-
private :client
|
7
|
-
|
8
|
-
def initialize(client)
|
9
|
-
@client = client
|
10
|
-
end
|
11
|
-
|
12
|
-
def list(sheet_id:, discussion_id:, params: {}, header_overrides: {})
|
13
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets', :sheet_id, 'discussions', :discussion_id, 'attachments'])
|
14
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
15
|
-
params: params,
|
16
|
-
header_overrides: header_overrides,
|
17
|
-
sheet_id: sheet_id,
|
18
|
-
discussion_id: discussion_id
|
19
|
-
)
|
20
|
-
client.make_request(endpoint_spec, request_spec)
|
21
|
-
end
|
22
|
-
end
|
1
|
+
module Smartsheet
|
2
|
+
# Discussions Attachments Endpoints
|
3
|
+
# @see https://smartsheet-platform.github.io/api-docs/?ruby#attachments API Attachments Docs
|
4
|
+
class DiscussionsAttachments
|
5
|
+
attr_reader :client
|
6
|
+
private :client
|
7
|
+
|
8
|
+
def initialize(client)
|
9
|
+
@client = client
|
10
|
+
end
|
11
|
+
|
12
|
+
def list(sheet_id:, discussion_id:, params: {}, header_overrides: {})
|
13
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets', :sheet_id, 'discussions', :discussion_id, 'attachments'])
|
14
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
15
|
+
params: params,
|
16
|
+
header_overrides: header_overrides,
|
17
|
+
sheet_id: sheet_id,
|
18
|
+
discussion_id: discussion_id
|
19
|
+
)
|
20
|
+
client.make_request(endpoint_spec, request_spec)
|
21
|
+
end
|
22
|
+
end
|
23
23
|
end
|
@@ -1,96 +1,107 @@
|
|
1
|
-
require 'smartsheet/endpoints/sheets/rows_attachments'
|
2
|
-
|
3
|
-
module Smartsheet
|
4
|
-
# Rows Endpoints
|
5
|
-
# @see https://smartsheet-platform.github.io/api-docs/?ruby#rows API Rows Docs
|
6
|
-
#
|
7
|
-
# @!attribute [r] attachments
|
8
|
-
# @return [RowsAttachments]
|
9
|
-
class Rows
|
10
|
-
attr_reader :client, :attachments
|
11
|
-
private :client
|
12
|
-
|
13
|
-
def initialize(client)
|
14
|
-
@client = client
|
15
|
-
|
16
|
-
@attachments = RowsAttachments.new(client)
|
17
|
-
end
|
18
|
-
|
19
|
-
def add(sheet_id:, body:, params: {}, header_overrides: {})
|
20
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows'], body_type: :json)
|
21
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
22
|
-
header_overrides: header_overrides,
|
23
|
-
params: params,
|
24
|
-
body: body,
|
25
|
-
sheet_id: sheet_id
|
26
|
-
)
|
27
|
-
client.make_request(endpoint_spec, request_spec)
|
28
|
-
end
|
29
|
-
|
30
|
-
def copy_to_another_sheet(sheet_id:, body:, params: {}, header_overrides: {})
|
31
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows', 'copy'], body_type: :json)
|
32
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
33
|
-
header_overrides: header_overrides,
|
34
|
-
body: body,
|
35
|
-
params: params,
|
36
|
-
sheet_id: sheet_id
|
37
|
-
)
|
38
|
-
client.make_request(endpoint_spec, request_spec)
|
39
|
-
end
|
40
|
-
|
41
|
-
def delete(sheet_id:, row_ids:, params: {}, header_overrides: {})
|
42
|
-
params[:ids] = row_ids.join(',')
|
43
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:delete, ['sheets', :sheet_id, 'rows'])
|
44
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
45
|
-
header_overrides: header_overrides,
|
46
|
-
params: params,
|
47
|
-
sheet_id: sheet_id
|
48
|
-
)
|
49
|
-
client.make_request(endpoint_spec, request_spec)
|
50
|
-
end
|
51
|
-
|
52
|
-
def get(sheet_id:, row_id:, params: {}, header_overrides: {})
|
53
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets', :sheet_id, 'rows', :row_id])
|
54
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
55
|
-
header_overrides: header_overrides,
|
56
|
-
params: params,
|
57
|
-
sheet_id: sheet_id,
|
58
|
-
row_id: row_id
|
59
|
-
)
|
60
|
-
client.make_request(endpoint_spec, request_spec)
|
61
|
-
end
|
62
|
-
|
63
|
-
def move_to_another_sheet(sheet_id:, body:, params: {}, header_overrides: {})
|
64
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows', 'move'], body_type: :json)
|
65
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
66
|
-
header_overrides: header_overrides,
|
67
|
-
body: body,
|
68
|
-
params: params,
|
69
|
-
sheet_id: sheet_id
|
70
|
-
)
|
71
|
-
client.make_request(endpoint_spec, request_spec)
|
72
|
-
end
|
73
|
-
|
74
|
-
def send_via_email(sheet_id:, body:, params: {}, header_overrides: {})
|
75
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows', 'emails'], body_type: :json)
|
76
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
77
|
-
header_overrides: header_overrides,
|
78
|
-
params: params,
|
79
|
-
body: body,
|
80
|
-
sheet_id: sheet_id
|
81
|
-
)
|
82
|
-
client.make_request(endpoint_spec, request_spec)
|
83
|
-
end
|
84
|
-
|
85
|
-
def update(sheet_id:, body:, params: {}, header_overrides: {})
|
86
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:put, ['sheets', :sheet_id, 'rows'], body_type: :json)
|
87
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
88
|
-
header_overrides: header_overrides,
|
89
|
-
body: body,
|
90
|
-
params: params,
|
91
|
-
sheet_id: sheet_id
|
92
|
-
)
|
93
|
-
client.make_request(endpoint_spec, request_spec)
|
94
|
-
end
|
95
|
-
|
1
|
+
require 'smartsheet/endpoints/sheets/rows_attachments'
|
2
|
+
|
3
|
+
module Smartsheet
|
4
|
+
# Rows Endpoints
|
5
|
+
# @see https://smartsheet-platform.github.io/api-docs/?ruby#rows API Rows Docs
|
6
|
+
#
|
7
|
+
# @!attribute [r] attachments
|
8
|
+
# @return [RowsAttachments]
|
9
|
+
class Rows
|
10
|
+
attr_reader :client, :attachments
|
11
|
+
private :client
|
12
|
+
|
13
|
+
def initialize(client)
|
14
|
+
@client = client
|
15
|
+
|
16
|
+
@attachments = RowsAttachments.new(client)
|
17
|
+
end
|
18
|
+
|
19
|
+
def add(sheet_id:, body:, params: {}, header_overrides: {})
|
20
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows'], body_type: :json)
|
21
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
22
|
+
header_overrides: header_overrides,
|
23
|
+
params: params,
|
24
|
+
body: body,
|
25
|
+
sheet_id: sheet_id
|
26
|
+
)
|
27
|
+
client.make_request(endpoint_spec, request_spec)
|
28
|
+
end
|
29
|
+
|
30
|
+
def copy_to_another_sheet(sheet_id:, body:, params: {}, header_overrides: {})
|
31
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows', 'copy'], body_type: :json)
|
32
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
33
|
+
header_overrides: header_overrides,
|
34
|
+
body: body,
|
35
|
+
params: params,
|
36
|
+
sheet_id: sheet_id
|
37
|
+
)
|
38
|
+
client.make_request(endpoint_spec, request_spec)
|
39
|
+
end
|
40
|
+
|
41
|
+
def delete(sheet_id:, row_ids:, params: {}, header_overrides: {})
|
42
|
+
params[:ids] = row_ids.join(',')
|
43
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:delete, ['sheets', :sheet_id, 'rows'])
|
44
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
45
|
+
header_overrides: header_overrides,
|
46
|
+
params: params,
|
47
|
+
sheet_id: sheet_id
|
48
|
+
)
|
49
|
+
client.make_request(endpoint_spec, request_spec)
|
50
|
+
end
|
51
|
+
|
52
|
+
def get(sheet_id:, row_id:, params: {}, header_overrides: {})
|
53
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets', :sheet_id, 'rows', :row_id])
|
54
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
55
|
+
header_overrides: header_overrides,
|
56
|
+
params: params,
|
57
|
+
sheet_id: sheet_id,
|
58
|
+
row_id: row_id
|
59
|
+
)
|
60
|
+
client.make_request(endpoint_spec, request_spec)
|
61
|
+
end
|
62
|
+
|
63
|
+
def move_to_another_sheet(sheet_id:, body:, params: {}, header_overrides: {})
|
64
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows', 'move'], body_type: :json)
|
65
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
66
|
+
header_overrides: header_overrides,
|
67
|
+
body: body,
|
68
|
+
params: params,
|
69
|
+
sheet_id: sheet_id
|
70
|
+
)
|
71
|
+
client.make_request(endpoint_spec, request_spec)
|
72
|
+
end
|
73
|
+
|
74
|
+
def send_via_email(sheet_id:, body:, params: {}, header_overrides: {})
|
75
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'rows', 'emails'], body_type: :json)
|
76
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
77
|
+
header_overrides: header_overrides,
|
78
|
+
params: params,
|
79
|
+
body: body,
|
80
|
+
sheet_id: sheet_id
|
81
|
+
)
|
82
|
+
client.make_request(endpoint_spec, request_spec)
|
83
|
+
end
|
84
|
+
|
85
|
+
def update(sheet_id:, body:, params: {}, header_overrides: {})
|
86
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:put, ['sheets', :sheet_id, 'rows'], body_type: :json)
|
87
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
88
|
+
header_overrides: header_overrides,
|
89
|
+
body: body,
|
90
|
+
params: params,
|
91
|
+
sheet_id: sheet_id
|
92
|
+
)
|
93
|
+
client.make_request(endpoint_spec, request_spec)
|
94
|
+
end
|
95
|
+
|
96
|
+
def sort(sheet_id:, body:, params: {}, header_overrides: {})
|
97
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post, ['sheets', :sheet_id, 'sort'], body_type: :json)
|
98
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
99
|
+
header_overrides: header_overrides,
|
100
|
+
body: body,
|
101
|
+
params: params,
|
102
|
+
sheet_id: sheet_id
|
103
|
+
)
|
104
|
+
client.make_request(endpoint_spec, request_spec)
|
105
|
+
end
|
106
|
+
end
|
96
107
|
end
|
@@ -1,93 +1,93 @@
|
|
1
|
-
require 'smartsheet/api/file_spec'
|
2
|
-
|
3
|
-
module Smartsheet
|
4
|
-
# Rows Attachments Endpoints
|
5
|
-
# @see https://smartsheet-platform.github.io/api-docs/?ruby#attachments API Attachments Docs
|
6
|
-
class RowsAttachments
|
7
|
-
attr_reader :client
|
8
|
-
private :client
|
9
|
-
|
10
|
-
def initialize(client)
|
11
|
-
@client = client
|
12
|
-
end
|
13
|
-
|
14
|
-
def list(sheet_id:, row_id:, params: {}, header_overrides: {})
|
15
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
16
|
-
:get,
|
17
|
-
['sheets', :sheet_id, 'rows', :row_id, 'attachments']
|
18
|
-
)
|
19
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
20
|
-
params: params,
|
21
|
-
header_overrides: header_overrides,
|
22
|
-
sheet_id: sheet_id,
|
23
|
-
row_id: row_id
|
24
|
-
)
|
25
|
-
client.make_request(endpoint_spec, request_spec)
|
26
|
-
end
|
27
|
-
|
28
|
-
def attach_url(sheet_id:, row_id:, body:, params: {}, header_overrides: {})
|
29
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
30
|
-
:post,
|
31
|
-
['sheets', :sheet_id, 'rows', :row_id, 'attachments'],
|
32
|
-
body_type: :json
|
33
|
-
)
|
34
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
35
|
-
header_overrides: header_overrides,
|
36
|
-
params: params,
|
37
|
-
body: body,
|
38
|
-
sheet_id: sheet_id,
|
39
|
-
row_id: row_id
|
40
|
-
)
|
41
|
-
client.make_request(endpoint_spec, request_spec)
|
42
|
-
end
|
43
|
-
|
44
|
-
def attach_file(
|
45
|
-
sheet_id:,
|
46
|
-
row_id:,
|
47
|
-
file:,
|
48
|
-
filename:,
|
49
|
-
file_length:,
|
50
|
-
content_type: '',
|
51
|
-
params: {},
|
52
|
-
header_overrides: {}
|
53
|
-
)
|
54
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
55
|
-
:post,
|
56
|
-
['sheets', :sheet_id, 'rows', :row_id, 'attachments'],
|
57
|
-
body_type: :file
|
58
|
-
)
|
59
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
60
|
-
params: params,
|
61
|
-
header_overrides: header_overrides,
|
62
|
-
file_spec: Smartsheet::API::ObjectFileSpec.new(file, filename, file_length, content_type),
|
63
|
-
sheet_id: sheet_id,
|
64
|
-
row_id: row_id
|
65
|
-
)
|
66
|
-
client.make_request(endpoint_spec, request_spec)
|
67
|
-
end
|
68
|
-
|
69
|
-
def attach_file_from_path(
|
70
|
-
sheet_id:,
|
71
|
-
row_id:,
|
72
|
-
path:,
|
73
|
-
filename: nil,
|
74
|
-
content_type: '',
|
75
|
-
params: {},
|
76
|
-
header_overrides: {}
|
77
|
-
)
|
78
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
79
|
-
:post,
|
80
|
-
['sheets', :sheet_id, 'rows', :row_id, 'attachments'],
|
81
|
-
body_type: :file
|
82
|
-
)
|
83
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
84
|
-
params: params,
|
85
|
-
header_overrides: header_overrides,
|
86
|
-
file_spec: Smartsheet::API::PathFileSpec.new(path, filename, content_type),
|
87
|
-
sheet_id: sheet_id,
|
88
|
-
row_id: row_id
|
89
|
-
)
|
90
|
-
client.make_request(endpoint_spec, request_spec)
|
91
|
-
end
|
92
|
-
end
|
1
|
+
require 'smartsheet/api/file_spec'
|
2
|
+
|
3
|
+
module Smartsheet
|
4
|
+
# Rows Attachments Endpoints
|
5
|
+
# @see https://smartsheet-platform.github.io/api-docs/?ruby#attachments API Attachments Docs
|
6
|
+
class RowsAttachments
|
7
|
+
attr_reader :client
|
8
|
+
private :client
|
9
|
+
|
10
|
+
def initialize(client)
|
11
|
+
@client = client
|
12
|
+
end
|
13
|
+
|
14
|
+
def list(sheet_id:, row_id:, params: {}, header_overrides: {})
|
15
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
16
|
+
:get,
|
17
|
+
['sheets', :sheet_id, 'rows', :row_id, 'attachments']
|
18
|
+
)
|
19
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
20
|
+
params: params,
|
21
|
+
header_overrides: header_overrides,
|
22
|
+
sheet_id: sheet_id,
|
23
|
+
row_id: row_id
|
24
|
+
)
|
25
|
+
client.make_request(endpoint_spec, request_spec)
|
26
|
+
end
|
27
|
+
|
28
|
+
def attach_url(sheet_id:, row_id:, body:, params: {}, header_overrides: {})
|
29
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
30
|
+
:post,
|
31
|
+
['sheets', :sheet_id, 'rows', :row_id, 'attachments'],
|
32
|
+
body_type: :json
|
33
|
+
)
|
34
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
35
|
+
header_overrides: header_overrides,
|
36
|
+
params: params,
|
37
|
+
body: body,
|
38
|
+
sheet_id: sheet_id,
|
39
|
+
row_id: row_id
|
40
|
+
)
|
41
|
+
client.make_request(endpoint_spec, request_spec)
|
42
|
+
end
|
43
|
+
|
44
|
+
def attach_file(
|
45
|
+
sheet_id:,
|
46
|
+
row_id:,
|
47
|
+
file:,
|
48
|
+
filename:,
|
49
|
+
file_length:,
|
50
|
+
content_type: '',
|
51
|
+
params: {},
|
52
|
+
header_overrides: {}
|
53
|
+
)
|
54
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
55
|
+
:post,
|
56
|
+
['sheets', :sheet_id, 'rows', :row_id, 'attachments'],
|
57
|
+
body_type: :file
|
58
|
+
)
|
59
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
60
|
+
params: params,
|
61
|
+
header_overrides: header_overrides,
|
62
|
+
file_spec: Smartsheet::API::ObjectFileSpec.new(file, filename, file_length, content_type),
|
63
|
+
sheet_id: sheet_id,
|
64
|
+
row_id: row_id
|
65
|
+
)
|
66
|
+
client.make_request(endpoint_spec, request_spec)
|
67
|
+
end
|
68
|
+
|
69
|
+
def attach_file_from_path(
|
70
|
+
sheet_id:,
|
71
|
+
row_id:,
|
72
|
+
path:,
|
73
|
+
filename: nil,
|
74
|
+
content_type: '',
|
75
|
+
params: {},
|
76
|
+
header_overrides: {}
|
77
|
+
)
|
78
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
79
|
+
:post,
|
80
|
+
['sheets', :sheet_id, 'rows', :row_id, 'attachments'],
|
81
|
+
body_type: :file
|
82
|
+
)
|
83
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
84
|
+
params: params,
|
85
|
+
header_overrides: header_overrides,
|
86
|
+
file_spec: Smartsheet::API::PathFileSpec.new(path, filename, content_type),
|
87
|
+
sheet_id: sheet_id,
|
88
|
+
row_id: row_id
|
89
|
+
)
|
90
|
+
client.make_request(endpoint_spec, request_spec)
|
91
|
+
end
|
92
|
+
end
|
93
93
|
end
|
@@ -1,317 +1,326 @@
|
|
1
|
-
require 'smartsheet/api/endpoint_spec'
|
2
|
-
require 'smartsheet/api/request_spec'
|
3
|
-
require 'smartsheet/constants'
|
4
|
-
|
5
|
-
require 'smartsheet/endpoints/sheets/
|
6
|
-
require 'smartsheet/endpoints/sheets/
|
7
|
-
require 'smartsheet/endpoints/sheets/
|
8
|
-
require 'smartsheet/endpoints/sheets/
|
9
|
-
require 'smartsheet/endpoints/sheets/
|
10
|
-
require 'smartsheet/endpoints/sheets/
|
11
|
-
require 'smartsheet/endpoints/sheets/
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
#
|
17
|
-
#
|
18
|
-
#
|
19
|
-
# @!attribute [r]
|
20
|
-
# @return [
|
21
|
-
# @!attribute [r]
|
22
|
-
# @return [
|
23
|
-
# @!attribute [r]
|
24
|
-
# @return [
|
25
|
-
# @!attribute [r]
|
26
|
-
# @return [
|
27
|
-
# @!attribute [r]
|
28
|
-
# @return [
|
29
|
-
# @!attribute [r]
|
30
|
-
# @return [
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
@
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
)
|
55
|
-
|
56
|
-
end
|
57
|
-
|
58
|
-
def
|
59
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets'
|
60
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
61
|
-
params: params,
|
62
|
-
header_overrides: header_overrides
|
63
|
-
|
64
|
-
)
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
)
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
:
|
81
|
-
|
82
|
-
|
83
|
-
)
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
:
|
95
|
-
|
96
|
-
|
97
|
-
)
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
:
|
109
|
-
|
110
|
-
|
111
|
-
)
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
:
|
123
|
-
|
124
|
-
|
125
|
-
)
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
:
|
137
|
-
|
138
|
-
|
139
|
-
)
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
:
|
152
|
-
|
153
|
-
|
154
|
-
)
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
:
|
167
|
-
|
168
|
-
|
169
|
-
)
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
:
|
181
|
-
|
182
|
-
|
183
|
-
)
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
:
|
196
|
-
|
197
|
-
|
198
|
-
)
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
:
|
211
|
-
|
212
|
-
|
213
|
-
)
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
:
|
226
|
-
|
227
|
-
|
228
|
-
)
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
:
|
241
|
-
|
242
|
-
|
243
|
-
)
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
:
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
header_overrides: header_overrides,
|
270
|
-
|
271
|
-
)
|
272
|
-
client.make_request(endpoint_spec, request_spec)
|
273
|
-
end
|
274
|
-
|
275
|
-
def
|
276
|
-
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get,['
|
277
|
-
request_spec = Smartsheet::API::RequestSpec.new(
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
)
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
)
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
1
|
+
require 'smartsheet/api/endpoint_spec'
|
2
|
+
require 'smartsheet/api/request_spec'
|
3
|
+
require 'smartsheet/constants'
|
4
|
+
|
5
|
+
require 'smartsheet/endpoints/sheets/automation_rules'
|
6
|
+
require 'smartsheet/endpoints/sheets/cells'
|
7
|
+
require 'smartsheet/endpoints/sheets/columns'
|
8
|
+
require 'smartsheet/endpoints/sheets/comments'
|
9
|
+
require 'smartsheet/endpoints/sheets/cross_sheet_references'
|
10
|
+
require 'smartsheet/endpoints/sheets/discussions'
|
11
|
+
require 'smartsheet/endpoints/sheets/rows'
|
12
|
+
require 'smartsheet/endpoints/sheets/sheets_attachments'
|
13
|
+
require 'smartsheet/endpoints/sheets/sheets_share'
|
14
|
+
|
15
|
+
module Smartsheet
|
16
|
+
# Sheets Endpoints
|
17
|
+
# @see https://smartsheet-platform.github.io/api-docs/?ruby#sheets API Sheets Docs
|
18
|
+
#
|
19
|
+
# @!attribute [r] attachments
|
20
|
+
# @return [SheetsAttachments]
|
21
|
+
# @!attribute [r] automation_rules
|
22
|
+
# @return [AutomationRules]
|
23
|
+
# @!attribute [r] cells
|
24
|
+
# @return [Cells]
|
25
|
+
# @!attribute [r] columns
|
26
|
+
# @return [Columns]
|
27
|
+
# @!attribute [r] comments
|
28
|
+
# @return [Comments]
|
29
|
+
# @!attribute [r] cross_sheet_references
|
30
|
+
# @return [CrossSheetReferences]
|
31
|
+
# @!attribute [r] discussions
|
32
|
+
# @return [Discussions]
|
33
|
+
# @!attribute [r] rows
|
34
|
+
# @return [Rows]
|
35
|
+
# @!attribute [r] share
|
36
|
+
# @return [SheetsShare]
|
37
|
+
class Sheets
|
38
|
+
include Smartsheet::Constants
|
39
|
+
|
40
|
+
attr_reader :client, :attachments, :automation_rules, :cells, :columns, :comments,
|
41
|
+
:cross_sheet_references, :discussions, :rows, :share
|
42
|
+
private :client
|
43
|
+
|
44
|
+
def initialize(client)
|
45
|
+
@client = client
|
46
|
+
|
47
|
+
@attachments = SheetsAttachments.new(client)
|
48
|
+
@automation_rules = AutomationRules.new(client)
|
49
|
+
@cells = Cells.new(client)
|
50
|
+
@columns = Columns.new(client)
|
51
|
+
@comments = Comments.new(client)
|
52
|
+
@cross_sheet_references = CrossSheetReferences.new(client)
|
53
|
+
@discussions = Discussions.new(client)
|
54
|
+
@rows = Rows.new(client)
|
55
|
+
@share = SheetsShare.new(client)
|
56
|
+
end
|
57
|
+
|
58
|
+
def list(params: {}, header_overrides: {})
|
59
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets'])
|
60
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
61
|
+
params: params,
|
62
|
+
header_overrides: header_overrides
|
63
|
+
)
|
64
|
+
client.make_request(endpoint_spec, request_spec)
|
65
|
+
end
|
66
|
+
|
67
|
+
def get(sheet_id:, params: {}, header_overrides: {})
|
68
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets', :sheet_id])
|
69
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
70
|
+
params: params,
|
71
|
+
header_overrides: header_overrides,
|
72
|
+
sheet_id: sheet_id
|
73
|
+
)
|
74
|
+
client.make_request(endpoint_spec, request_spec)
|
75
|
+
end
|
76
|
+
|
77
|
+
def get_version(sheet_id:, params: {}, header_overrides: {})
|
78
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get, ['sheets', :sheet_id, 'version'])
|
79
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
80
|
+
params: params,
|
81
|
+
header_overrides: header_overrides,
|
82
|
+
sheet_id: sheet_id
|
83
|
+
)
|
84
|
+
client.make_request(endpoint_spec, request_spec)
|
85
|
+
end
|
86
|
+
|
87
|
+
def get_as_excel(sheet_id:, params: {}, header_overrides: {})
|
88
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
89
|
+
:get,
|
90
|
+
['sheets', :sheet_id],
|
91
|
+
headers: {Accept: EXCEL_TYPE}
|
92
|
+
)
|
93
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
94
|
+
params: params,
|
95
|
+
header_overrides: header_overrides,
|
96
|
+
sheet_id: sheet_id
|
97
|
+
)
|
98
|
+
client.make_request(endpoint_spec, request_spec)
|
99
|
+
end
|
100
|
+
|
101
|
+
def get_as_pdf(sheet_id:, params: {}, header_overrides: {})
|
102
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
103
|
+
:get,
|
104
|
+
['sheets', :sheet_id],
|
105
|
+
headers: {Accept: PDF_TYPE}
|
106
|
+
)
|
107
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
108
|
+
params: params,
|
109
|
+
header_overrides: header_overrides,
|
110
|
+
sheet_id: sheet_id
|
111
|
+
)
|
112
|
+
client.make_request(endpoint_spec, request_spec)
|
113
|
+
end
|
114
|
+
|
115
|
+
def get_as_csv(sheet_id:, params: {}, header_overrides: {})
|
116
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
117
|
+
:get,
|
118
|
+
['sheets', :sheet_id],
|
119
|
+
headers: {Accept: CSV_TYPE}
|
120
|
+
)
|
121
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
122
|
+
params: params,
|
123
|
+
header_overrides: header_overrides,
|
124
|
+
sheet_id: sheet_id
|
125
|
+
)
|
126
|
+
client.make_request(endpoint_spec, request_spec)
|
127
|
+
end
|
128
|
+
|
129
|
+
def create(body:, params: {}, header_overrides: {})
|
130
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
131
|
+
:post,
|
132
|
+
['sheets'],
|
133
|
+
body_type: :json
|
134
|
+
)
|
135
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
136
|
+
params: params,
|
137
|
+
header_overrides: header_overrides,
|
138
|
+
body: body
|
139
|
+
)
|
140
|
+
client.make_request(endpoint_spec, request_spec)
|
141
|
+
end
|
142
|
+
|
143
|
+
def create_in_folder(folder_id:, body:, params: {}, header_overrides: {})
|
144
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
145
|
+
:post,
|
146
|
+
['folders', :folder_id, 'sheets'],
|
147
|
+
body_type: :json
|
148
|
+
)
|
149
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
150
|
+
params: params,
|
151
|
+
header_overrides: header_overrides,
|
152
|
+
body: body,
|
153
|
+
folder_id: folder_id
|
154
|
+
)
|
155
|
+
client.make_request(endpoint_spec, request_spec)
|
156
|
+
end
|
157
|
+
|
158
|
+
def create_in_workspace(workspace_id:, body:, params: {}, header_overrides: {})
|
159
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
160
|
+
:post,
|
161
|
+
['workspaces', :workspace_id, 'sheets'],
|
162
|
+
body_type: :json
|
163
|
+
)
|
164
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
165
|
+
params: params,
|
166
|
+
header_overrides: header_overrides,
|
167
|
+
body: body,
|
168
|
+
workspace_id: workspace_id
|
169
|
+
)
|
170
|
+
client.make_request(endpoint_spec, request_spec)
|
171
|
+
end
|
172
|
+
|
173
|
+
def create_from_template(body:, params: {}, header_overrides: {})
|
174
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
175
|
+
:post,
|
176
|
+
['sheets'],
|
177
|
+
body_type: :json
|
178
|
+
)
|
179
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
180
|
+
params: params,
|
181
|
+
header_overrides: header_overrides,
|
182
|
+
body: body
|
183
|
+
)
|
184
|
+
client.make_request(endpoint_spec, request_spec)
|
185
|
+
end
|
186
|
+
|
187
|
+
def create_in_folder_from_template(folder_id:, body:, params: {}, header_overrides: {})
|
188
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
189
|
+
:post,
|
190
|
+
['folders', :folder_id, 'sheets'],
|
191
|
+
body_type: :json
|
192
|
+
)
|
193
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
194
|
+
params: params,
|
195
|
+
header_overrides: header_overrides,
|
196
|
+
body: body,
|
197
|
+
folder_id: folder_id
|
198
|
+
)
|
199
|
+
client.make_request(endpoint_spec, request_spec)
|
200
|
+
end
|
201
|
+
|
202
|
+
def create_in_workspace_from_template(workspace_id:, body:, params: {}, header_overrides: {})
|
203
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
204
|
+
:post,
|
205
|
+
['workspaces', :workspace_id, 'sheets'],
|
206
|
+
body_type: :json
|
207
|
+
)
|
208
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
209
|
+
params: params,
|
210
|
+
header_overrides: header_overrides,
|
211
|
+
body: body,
|
212
|
+
workspace_id: workspace_id
|
213
|
+
)
|
214
|
+
client.make_request(endpoint_spec, request_spec)
|
215
|
+
end
|
216
|
+
|
217
|
+
def copy(sheet_id:, body:, params: {}, header_overrides: {})
|
218
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
219
|
+
:post,
|
220
|
+
['sheets', :sheet_id, 'copy'],
|
221
|
+
body_type: :json
|
222
|
+
)
|
223
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
224
|
+
params: params,
|
225
|
+
header_overrides: header_overrides,
|
226
|
+
body: body,
|
227
|
+
sheet_id: sheet_id
|
228
|
+
)
|
229
|
+
client.make_request(endpoint_spec, request_spec)
|
230
|
+
end
|
231
|
+
|
232
|
+
def move(sheet_id:, body:, params: {}, header_overrides: {})
|
233
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
234
|
+
:post,
|
235
|
+
['sheets', :sheet_id, 'move'],
|
236
|
+
body_type: :json
|
237
|
+
)
|
238
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
239
|
+
params: params,
|
240
|
+
header_overrides: header_overrides,
|
241
|
+
body: body,
|
242
|
+
sheet_id: sheet_id
|
243
|
+
)
|
244
|
+
client.make_request(endpoint_spec, request_spec)
|
245
|
+
end
|
246
|
+
|
247
|
+
def update(sheet_id:, body:, params: {}, header_overrides: {})
|
248
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
249
|
+
:put,
|
250
|
+
['sheets', :sheet_id],
|
251
|
+
body_type: :json
|
252
|
+
)
|
253
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
254
|
+
params: params,
|
255
|
+
header_overrides: header_overrides,
|
256
|
+
body: body,
|
257
|
+
sheet_id: sheet_id
|
258
|
+
)
|
259
|
+
client.make_request(endpoint_spec, request_spec)
|
260
|
+
end
|
261
|
+
|
262
|
+
def delete(sheet_id:, params: {}, header_overrides: {})
|
263
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(
|
264
|
+
:delete,
|
265
|
+
['sheets', :sheet_id]
|
266
|
+
)
|
267
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
268
|
+
params: params,
|
269
|
+
header_overrides: header_overrides,
|
270
|
+
sheet_id: sheet_id
|
271
|
+
)
|
272
|
+
client.make_request(endpoint_spec, request_spec)
|
273
|
+
end
|
274
|
+
|
275
|
+
def list_for_org(params: {}, header_overrides: {})
|
276
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get,['users', 'sheets'])
|
277
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
278
|
+
header_overrides: header_overrides,
|
279
|
+
params: params
|
280
|
+
)
|
281
|
+
client.make_request(endpoint_spec, request_spec)
|
282
|
+
end
|
283
|
+
|
284
|
+
def get_publish_status(sheet_id:, params: {}, header_overrides: {})
|
285
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:get,['sheets', :sheet_id, 'publish'])
|
286
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
287
|
+
params: params,
|
288
|
+
header_overrides: header_overrides,
|
289
|
+
sheet_id: sheet_id
|
290
|
+
)
|
291
|
+
client.make_request(endpoint_spec, request_spec)
|
292
|
+
end
|
293
|
+
|
294
|
+
def set_publish_status(sheet_id:, body:, params: {}, header_overrides: {})
|
295
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:put,['sheets', :sheet_id, 'publish'], body_type: :json)
|
296
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
297
|
+
params: params,
|
298
|
+
header_overrides: header_overrides,
|
299
|
+
body: body,
|
300
|
+
sheet_id: sheet_id
|
301
|
+
)
|
302
|
+
client.make_request(endpoint_spec, request_spec)
|
303
|
+
end
|
304
|
+
|
305
|
+
def send_via_email(sheet_id:, body:, params: {}, header_overrides: {})
|
306
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post,['sheets', :sheet_id, 'emails'], body_type: :json)
|
307
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
308
|
+
params: params,
|
309
|
+
header_overrides: header_overrides,
|
310
|
+
body: body,
|
311
|
+
sheet_id: sheet_id
|
312
|
+
)
|
313
|
+
client.make_request(endpoint_spec, request_spec)
|
314
|
+
end
|
315
|
+
|
316
|
+
def list_image_urls(body:, params: {}, header_overrides: {})
|
317
|
+
endpoint_spec = Smartsheet::API::EndpointSpec.new(:post,['imageurls'], body_type: :json)
|
318
|
+
request_spec = Smartsheet::API::RequestSpec.new(
|
319
|
+
params: params,
|
320
|
+
header_overrides: header_overrides,
|
321
|
+
body: body
|
322
|
+
)
|
323
|
+
client.make_request(endpoint_spec, request_spec)
|
324
|
+
end
|
325
|
+
end
|
326
|
+
end
|