signrequest_client 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (188) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +7 -0
  3. data/Gemfile.lock +69 -0
  4. data/LICENSE +21 -0
  5. data/README.md +122 -0
  6. data/Rakefile +9 -0
  7. data/docs/ApiTokensApi.md +226 -0
  8. data/docs/AuthToken.md +13 -0
  9. data/docs/Document.md +33 -0
  10. data/docs/DocumentAttachment.md +15 -0
  11. data/docs/DocumentAttachmentsApi.md +179 -0
  12. data/docs/DocumentSearch.md +22 -0
  13. data/docs/DocumentSignerTemplateConf.md +14 -0
  14. data/docs/DocumentsApi.md +301 -0
  15. data/docs/DocumentsSearchApi.md +119 -0
  16. data/docs/Event.md +17 -0
  17. data/docs/EventsApi.md +145 -0
  18. data/docs/FileFromSf.md +9 -0
  19. data/docs/InlineDocumentSignerIntegrationData.md +9 -0
  20. data/docs/InlineIntegrationData.md +9 -0
  21. data/docs/InlinePrefillTags.md +11 -0
  22. data/docs/InlineResponse200.md +11 -0
  23. data/docs/InlineResponse2001.md +11 -0
  24. data/docs/InlineResponse2002.md +11 -0
  25. data/docs/InlineResponse2003.md +11 -0
  26. data/docs/InlineResponse2004.md +11 -0
  27. data/docs/InlineResponse2005.md +11 -0
  28. data/docs/InlineResponse2006.md +11 -0
  29. data/docs/InlineResponse2007.md +11 -0
  30. data/docs/InlineResponse2008.md +11 -0
  31. data/docs/InlineResponse2009.md +11 -0
  32. data/docs/InlineSignRequest.md +25 -0
  33. data/docs/InlineTeam.md +10 -0
  34. data/docs/InlineTeamMember.md +13 -0
  35. data/docs/InviteMember.md +10 -0
  36. data/docs/Placeholder.md +15 -0
  37. data/docs/RequiredAttachment.md +9 -0
  38. data/docs/SignRequest.md +29 -0
  39. data/docs/SignRequestQuickCreate.md +42 -0
  40. data/docs/Signer.md +40 -0
  41. data/docs/SignerAttachment.md +11 -0
  42. data/docs/SignerInputs.md +14 -0
  43. data/docs/SigningLog.md +9 -0
  44. data/docs/SignrequestQuickCreateApi.md +62 -0
  45. data/docs/SignrequestsApi.md +291 -0
  46. data/docs/Team.md +15 -0
  47. data/docs/TeamMember.md +14 -0
  48. data/docs/TeamMembersApi.md +131 -0
  49. data/docs/TeamsApi.md +344 -0
  50. data/docs/Template.md +14 -0
  51. data/docs/TemplatesApi.md +119 -0
  52. data/docs/User.md +11 -0
  53. data/docs/WebhookSubscription.md +15 -0
  54. data/docs/WebhooksApi.md +340 -0
  55. data/git_push.sh +55 -0
  56. data/lib/signrequest_client/api/api_tokens_api.rb +242 -0
  57. data/lib/signrequest_client/api/document_attachments_api.rb +197 -0
  58. data/lib/signrequest_client/api/documents_api.rb +330 -0
  59. data/lib/signrequest_client/api/documents_search_api.rb +133 -0
  60. data/lib/signrequest_client/api/events_api.rb +172 -0
  61. data/lib/signrequest_client/api/signrequest_quick_create_api.rb +78 -0
  62. data/lib/signrequest_client/api/signrequests_api.rb +316 -0
  63. data/lib/signrequest_client/api/team_members_api.rb +151 -0
  64. data/lib/signrequest_client/api/teams_api.rb +371 -0
  65. data/lib/signrequest_client/api/templates_api.rb +133 -0
  66. data/lib/signrequest_client/api/webhooks_api.rb +364 -0
  67. data/lib/signrequest_client/api_client.rb +389 -0
  68. data/lib/signrequest_client/api_error.rb +38 -0
  69. data/lib/signrequest_client/configuration.rb +209 -0
  70. data/lib/signrequest_client/models/auth_token.rb +298 -0
  71. data/lib/signrequest_client/models/document.rb +605 -0
  72. data/lib/signrequest_client/models/document_attachment.rb +304 -0
  73. data/lib/signrequest_client/models/document_search.rb +519 -0
  74. data/lib/signrequest_client/models/document_signer_template_conf.rb +294 -0
  75. data/lib/signrequest_client/models/event.rb +330 -0
  76. data/lib/signrequest_client/models/file_from_sf.rb +245 -0
  77. data/lib/signrequest_client/models/inline_document_signer_integration_data.rb +230 -0
  78. data/lib/signrequest_client/models/inline_integration_data.rb +230 -0
  79. data/lib/signrequest_client/models/inline_prefill_tags.rb +231 -0
  80. data/lib/signrequest_client/models/inline_response_200.rb +227 -0
  81. data/lib/signrequest_client/models/inline_response_200_1.rb +227 -0
  82. data/lib/signrequest_client/models/inline_response_200_2.rb +227 -0
  83. data/lib/signrequest_client/models/inline_response_200_3.rb +227 -0
  84. data/lib/signrequest_client/models/inline_response_200_4.rb +227 -0
  85. data/lib/signrequest_client/models/inline_response_200_5.rb +227 -0
  86. data/lib/signrequest_client/models/inline_response_200_6.rb +227 -0
  87. data/lib/signrequest_client/models/inline_response_200_7.rb +227 -0
  88. data/lib/signrequest_client/models/inline_response_200_8.rb +227 -0
  89. data/lib/signrequest_client/models/inline_response_200_9.rb +227 -0
  90. data/lib/signrequest_client/models/inline_sign_request.rb +496 -0
  91. data/lib/signrequest_client/models/inline_team.rb +247 -0
  92. data/lib/signrequest_client/models/inline_team_member.rb +249 -0
  93. data/lib/signrequest_client/models/invite_member.rb +234 -0
  94. data/lib/signrequest_client/models/placeholder.rb +326 -0
  95. data/lib/signrequest_client/models/required_attachment.rb +246 -0
  96. data/lib/signrequest_client/models/sign_request.rb +543 -0
  97. data/lib/signrequest_client/models/sign_request_quick_create.rb +764 -0
  98. data/lib/signrequest_client/models/signer.rb +751 -0
  99. data/lib/signrequest_client/models/signer_attachment.rb +247 -0
  100. data/lib/signrequest_client/models/signer_inputs.rb +312 -0
  101. data/lib/signrequest_client/models/signing_log.rb +213 -0
  102. data/lib/signrequest_client/models/team.rb +367 -0
  103. data/lib/signrequest_client/models/team_member.rb +258 -0
  104. data/lib/signrequest_client/models/template.rb +309 -0
  105. data/lib/signrequest_client/models/user.rb +296 -0
  106. data/lib/signrequest_client/models/webhook_subscription.rb +366 -0
  107. data/lib/signrequest_client/version.rb +15 -0
  108. data/lib/signrequest_client.rb +87 -0
  109. data/pkg/signrequest_client-0.1.0.gem +0 -0
  110. data/signrequest_client.gemspec +45 -0
  111. data/signrequst_client/.git/HEAD +1 -0
  112. data/signrequst_client/.git/config +7 -0
  113. data/signrequst_client/.git/description +1 -0
  114. data/signrequst_client/.git/hooks/applypatch-msg.sample +15 -0
  115. data/signrequst_client/.git/hooks/commit-msg.sample +24 -0
  116. data/signrequst_client/.git/hooks/fsmonitor-watchman.sample +114 -0
  117. data/signrequst_client/.git/hooks/post-update.sample +8 -0
  118. data/signrequst_client/.git/hooks/pre-applypatch.sample +14 -0
  119. data/signrequst_client/.git/hooks/pre-commit.sample +49 -0
  120. data/signrequst_client/.git/hooks/pre-push.sample +53 -0
  121. data/signrequst_client/.git/hooks/pre-rebase.sample +169 -0
  122. data/signrequst_client/.git/hooks/pre-receive.sample +24 -0
  123. data/signrequst_client/.git/hooks/prepare-commit-msg.sample +42 -0
  124. data/signrequst_client/.git/hooks/update.sample +128 -0
  125. data/signrequst_client/.git/index +0 -0
  126. data/signrequst_client/.git/info/exclude +6 -0
  127. data/signrequst_client/.git/objects/30/68cc8a074ffc0c7b8891cb21d68b5d367cb8c4 +0 -0
  128. data/signrequst_client/.git/objects/32/c4b7e9f988621ed2ce28954f1aaf088f340848 +2 -0
  129. data/signrequst_client/.git/objects/3e/8c4c2f8d1d5334612f3072160124e985f27e8c +0 -0
  130. data/signrequst_client/.git/objects/43/022f711e20ed55baf2470278eb8e428a04856f +0 -0
  131. data/signrequst_client/.git/objects/6f/8caa83dfb6dc8a987a2829cbfefae18c8870c3 +0 -0
  132. data/signrequst_client/.git/objects/91/06b2a345b019a799c02e5069affa88370b35dd +0 -0
  133. data/signrequst_client/.git/objects/aa/58e53f733551ac2bde6f7a50b5a9f16ddbf110 +0 -0
  134. data/signrequst_client/.git/objects/dc/e67d860af47a4eb630117ce03624bae45dcf26 +3 -0
  135. data/signrequst_client/.git/objects/f1/c9171bed4c19fd22429ffd68d4cbb2c3ce2fce +0 -0
  136. data/signrequst_client/.git/objects/f8/e4c2573ebc57d5a365ebe14d5c18cc8d0716c4 +0 -0
  137. data/spec/api/api_tokens_api_spec.rb +84 -0
  138. data/spec/api/document_attachments_api_spec.rb +75 -0
  139. data/spec/api/documents_api_spec.rb +106 -0
  140. data/spec/api/documents_search_api_spec.rb +60 -0
  141. data/spec/api/events_api_spec.rb +73 -0
  142. data/spec/api/signrequest_quick_create_api_spec.rb +47 -0
  143. data/spec/api/signrequests_api_spec.rb +100 -0
  144. data/spec/api/team_members_api_spec.rb +66 -0
  145. data/spec/api/teams_api_spec.rb +111 -0
  146. data/spec/api/templates_api_spec.rb +60 -0
  147. data/spec/api/webhooks_api_spec.rb +110 -0
  148. data/spec/api_client_spec.rb +226 -0
  149. data/spec/configuration_spec.rb +42 -0
  150. data/spec/models/auth_token_spec.rb +72 -0
  151. data/spec/models/document_attachment_spec.rb +84 -0
  152. data/spec/models/document_search_spec.rb +126 -0
  153. data/spec/models/document_signer_template_conf_spec.rb +78 -0
  154. data/spec/models/document_spec.rb +196 -0
  155. data/spec/models/event_spec.rb +104 -0
  156. data/spec/models/file_from_sf_spec.rb +48 -0
  157. data/spec/models/inline_document_signer_integration_data_spec.rb +52 -0
  158. data/spec/models/inline_integration_data_spec.rb +52 -0
  159. data/spec/models/inline_prefill_tags_spec.rb +60 -0
  160. data/spec/models/inline_response_200_1_spec.rb +60 -0
  161. data/spec/models/inline_response_200_2_spec.rb +60 -0
  162. data/spec/models/inline_response_200_3_spec.rb +60 -0
  163. data/spec/models/inline_response_200_4_spec.rb +60 -0
  164. data/spec/models/inline_response_200_5_spec.rb +60 -0
  165. data/spec/models/inline_response_200_6_spec.rb +60 -0
  166. data/spec/models/inline_response_200_7_spec.rb +60 -0
  167. data/spec/models/inline_response_200_8_spec.rb +60 -0
  168. data/spec/models/inline_response_200_9_spec.rb +60 -0
  169. data/spec/models/inline_response_200_spec.rb +60 -0
  170. data/spec/models/inline_sign_request_spec.rb +148 -0
  171. data/spec/models/inline_team_member_spec.rb +72 -0
  172. data/spec/models/inline_team_spec.rb +54 -0
  173. data/spec/models/invite_member_spec.rb +54 -0
  174. data/spec/models/placeholder_spec.rb +88 -0
  175. data/spec/models/required_attachment_spec.rb +48 -0
  176. data/spec/models/sign_request_quick_create_spec.rb +254 -0
  177. data/spec/models/sign_request_spec.rb +176 -0
  178. data/spec/models/signer_attachment_spec.rb +60 -0
  179. data/spec/models/signer_inputs_spec.rb +82 -0
  180. data/spec/models/signer_spec.rb +238 -0
  181. data/spec/models/signing_log_spec.rb +48 -0
  182. data/spec/models/team_member_spec.rb +78 -0
  183. data/spec/models/team_spec.rb +84 -0
  184. data/spec/models/template_spec.rb +82 -0
  185. data/spec/models/user_spec.rb +60 -0
  186. data/spec/models/webhook_subscription_spec.rb +92 -0
  187. data/spec/spec_helper.rb +111 -0
  188. metadata +461 -0
@@ -0,0 +1,197 @@
1
+ =begin
2
+ #SignRequest API
3
+
4
+ #API for SignRequest.com
5
+
6
+ OpenAPI spec version: v1
7
+ Contact: tech-support@signrequest.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.3.1
10
+
11
+ =end
12
+
13
+ require "uri"
14
+
15
+ module SignRequestClient
16
+ class DocumentAttachmentsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+
23
+ #
24
+ #
25
+ # @param data
26
+ # @param [Hash] opts the optional parameters
27
+ # @return [DocumentAttachment]
28
+ def document_attachments_create(data, opts = {})
29
+ data, _status_code, _headers = document_attachments_create_with_http_info(data, opts)
30
+ return data
31
+ end
32
+
33
+ #
34
+ #
35
+ # @param data
36
+ # @param [Hash] opts the optional parameters
37
+ # @return [Array<(DocumentAttachment, Fixnum, Hash)>] DocumentAttachment data, response status code and response headers
38
+ def document_attachments_create_with_http_info(data, opts = {})
39
+ if @api_client.config.debugging
40
+ @api_client.config.logger.debug "Calling API: DocumentAttachmentsApi.document_attachments_create ..."
41
+ end
42
+ # verify the required parameter 'data' is set
43
+ if @api_client.config.client_side_validation && data.nil?
44
+ fail ArgumentError, "Missing the required parameter 'data' when calling DocumentAttachmentsApi.document_attachments_create"
45
+ end
46
+ # resource path
47
+ local_var_path = "/document-attachments/"
48
+
49
+ # query parameters
50
+ query_params = {}
51
+
52
+ # header parameters
53
+ header_params = {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
56
+ # HTTP header 'Content-Type'
57
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
58
+
59
+ # form parameters
60
+ form_params = {}
61
+
62
+ # http body (model)
63
+ post_body = @api_client.object_to_http_body(data)
64
+ auth_names = ['Token']
65
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
66
+ :header_params => header_params,
67
+ :query_params => query_params,
68
+ :form_params => form_params,
69
+ :body => post_body,
70
+ :auth_names => auth_names,
71
+ :return_type => 'DocumentAttachment')
72
+ if @api_client.config.debugging
73
+ @api_client.config.logger.debug "API called: DocumentAttachmentsApi#document_attachments_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
+ end
75
+ return data, status_code, headers
76
+ end
77
+
78
+ #
79
+ #
80
+ # @param [Hash] opts the optional parameters
81
+ # @option opts [String] :document__uuid
82
+ # @option opts [String] :document__external_id
83
+ # @option opts [String] :created
84
+ # @option opts [Integer] :page A page number within the paginated result set.
85
+ # @option opts [Integer] :limit Number of results to return per page.
86
+ # @return [InlineResponse2001]
87
+ def document_attachments_list(opts = {})
88
+ data, _status_code, _headers = document_attachments_list_with_http_info(opts)
89
+ return data
90
+ end
91
+
92
+ #
93
+ #
94
+ # @param [Hash] opts the optional parameters
95
+ # @option opts [String] :document__uuid
96
+ # @option opts [String] :document__external_id
97
+ # @option opts [String] :created
98
+ # @option opts [Integer] :page A page number within the paginated result set.
99
+ # @option opts [Integer] :limit Number of results to return per page.
100
+ # @return [Array<(InlineResponse2001, Fixnum, Hash)>] InlineResponse2001 data, response status code and response headers
101
+ def document_attachments_list_with_http_info(opts = {})
102
+ if @api_client.config.debugging
103
+ @api_client.config.logger.debug "Calling API: DocumentAttachmentsApi.document_attachments_list ..."
104
+ end
105
+ # resource path
106
+ local_var_path = "/document-attachments/"
107
+
108
+ # query parameters
109
+ query_params = {}
110
+ query_params[:'document__uuid'] = opts[:'document__uuid'] if !opts[:'document__uuid'].nil?
111
+ query_params[:'document__external_id'] = opts[:'document__external_id'] if !opts[:'document__external_id'].nil?
112
+ query_params[:'created'] = opts[:'created'] if !opts[:'created'].nil?
113
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
114
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
115
+
116
+ # header parameters
117
+ header_params = {}
118
+ # HTTP header 'Accept' (if needed)
119
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
120
+ # HTTP header 'Content-Type'
121
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
122
+
123
+ # form parameters
124
+ form_params = {}
125
+
126
+ # http body (model)
127
+ post_body = nil
128
+ auth_names = ['Token']
129
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
130
+ :header_params => header_params,
131
+ :query_params => query_params,
132
+ :form_params => form_params,
133
+ :body => post_body,
134
+ :auth_names => auth_names,
135
+ :return_type => 'InlineResponse2001')
136
+ if @api_client.config.debugging
137
+ @api_client.config.logger.debug "API called: DocumentAttachmentsApi#document_attachments_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
138
+ end
139
+ return data, status_code, headers
140
+ end
141
+
142
+ #
143
+ #
144
+ # @param uuid
145
+ # @param [Hash] opts the optional parameters
146
+ # @return [DocumentAttachment]
147
+ def document_attachments_read(uuid, opts = {})
148
+ data, _status_code, _headers = document_attachments_read_with_http_info(uuid, opts)
149
+ return data
150
+ end
151
+
152
+ #
153
+ #
154
+ # @param uuid
155
+ # @param [Hash] opts the optional parameters
156
+ # @return [Array<(DocumentAttachment, Fixnum, Hash)>] DocumentAttachment data, response status code and response headers
157
+ def document_attachments_read_with_http_info(uuid, opts = {})
158
+ if @api_client.config.debugging
159
+ @api_client.config.logger.debug "Calling API: DocumentAttachmentsApi.document_attachments_read ..."
160
+ end
161
+ # verify the required parameter 'uuid' is set
162
+ if @api_client.config.client_side_validation && uuid.nil?
163
+ fail ArgumentError, "Missing the required parameter 'uuid' when calling DocumentAttachmentsApi.document_attachments_read"
164
+ end
165
+ # resource path
166
+ local_var_path = "/document-attachments/{uuid}/".sub('{' + 'uuid' + '}', uuid.to_s)
167
+
168
+ # query parameters
169
+ query_params = {}
170
+
171
+ # header parameters
172
+ header_params = {}
173
+ # HTTP header 'Accept' (if needed)
174
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
175
+ # HTTP header 'Content-Type'
176
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
177
+
178
+ # form parameters
179
+ form_params = {}
180
+
181
+ # http body (model)
182
+ post_body = nil
183
+ auth_names = ['Token']
184
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
185
+ :header_params => header_params,
186
+ :query_params => query_params,
187
+ :form_params => form_params,
188
+ :body => post_body,
189
+ :auth_names => auth_names,
190
+ :return_type => 'DocumentAttachment')
191
+ if @api_client.config.debugging
192
+ @api_client.config.logger.debug "API called: DocumentAttachmentsApi#document_attachments_read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
193
+ end
194
+ return data, status_code, headers
195
+ end
196
+ end
197
+ end
@@ -0,0 +1,330 @@
1
+ =begin
2
+ #SignRequest API
3
+
4
+ #API for SignRequest.com
5
+
6
+ OpenAPI spec version: v1
7
+ Contact: tech-support@signrequest.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.3.1
10
+
11
+ =end
12
+
13
+ require "uri"
14
+
15
+ module SignRequestClient
16
+ class DocumentsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+
23
+ #
24
+ #
25
+ # @param data
26
+ # @param [Hash] opts the optional parameters
27
+ # @return [Document]
28
+ def documents_create(data, opts = {})
29
+ data, _status_code, _headers = documents_create_with_http_info(data, opts)
30
+ return data
31
+ end
32
+
33
+ #
34
+ #
35
+ # @param data
36
+ # @param [Hash] opts the optional parameters
37
+ # @return [Array<(Document, Fixnum, Hash)>] Document data, response status code and response headers
38
+ def documents_create_with_http_info(data, opts = {})
39
+ if @api_client.config.debugging
40
+ @api_client.config.logger.debug "Calling API: DocumentsApi.documents_create ..."
41
+ end
42
+ # verify the required parameter 'data' is set
43
+ if @api_client.config.client_side_validation && data.nil?
44
+ fail ArgumentError, "Missing the required parameter 'data' when calling DocumentsApi.documents_create"
45
+ end
46
+ # resource path
47
+ local_var_path = "/documents/"
48
+
49
+ # query parameters
50
+ query_params = {}
51
+
52
+ # header parameters
53
+ header_params = {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
56
+ # HTTP header 'Content-Type'
57
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
58
+
59
+ # form parameters
60
+ form_params = {}
61
+
62
+ # http body (model)
63
+ post_body = @api_client.object_to_http_body(data)
64
+ auth_names = ['Token']
65
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
66
+ :header_params => header_params,
67
+ :query_params => query_params,
68
+ :form_params => form_params,
69
+ :body => post_body,
70
+ :auth_names => auth_names,
71
+ :return_type => 'Document')
72
+ if @api_client.config.debugging
73
+ @api_client.config.logger.debug "API called: DocumentsApi#documents_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
+ end
75
+ return data, status_code, headers
76
+ end
77
+
78
+ #
79
+ #
80
+ # @param uuid
81
+ # @param [Hash] opts the optional parameters
82
+ # @return [nil]
83
+ def documents_delete(uuid, opts = {})
84
+ documents_delete_with_http_info(uuid, opts)
85
+ return nil
86
+ end
87
+
88
+ #
89
+ #
90
+ # @param uuid
91
+ # @param [Hash] opts the optional parameters
92
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
93
+ def documents_delete_with_http_info(uuid, opts = {})
94
+ if @api_client.config.debugging
95
+ @api_client.config.logger.debug "Calling API: DocumentsApi.documents_delete ..."
96
+ end
97
+ # verify the required parameter 'uuid' is set
98
+ if @api_client.config.client_side_validation && uuid.nil?
99
+ fail ArgumentError, "Missing the required parameter 'uuid' when calling DocumentsApi.documents_delete"
100
+ end
101
+ # resource path
102
+ local_var_path = "/documents/{uuid}/".sub('{' + 'uuid' + '}', uuid.to_s)
103
+
104
+ # query parameters
105
+ query_params = {}
106
+
107
+ # header parameters
108
+ header_params = {}
109
+ # HTTP header 'Accept' (if needed)
110
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
111
+ # HTTP header 'Content-Type'
112
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
113
+
114
+ # form parameters
115
+ form_params = {}
116
+
117
+ # http body (model)
118
+ post_body = nil
119
+ auth_names = ['Token']
120
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
121
+ :header_params => header_params,
122
+ :query_params => query_params,
123
+ :form_params => form_params,
124
+ :body => post_body,
125
+ :auth_names => auth_names)
126
+ if @api_client.config.debugging
127
+ @api_client.config.logger.debug "API called: DocumentsApi#documents_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
128
+ end
129
+ return data, status_code, headers
130
+ end
131
+
132
+ #
133
+ # This is only for integration partners
134
+ # @param uuid
135
+ # @param data
136
+ # @param [Hash] opts the optional parameters
137
+ # @return [Document]
138
+ def documents_delete_files(uuid, data, opts = {})
139
+ data, _status_code, _headers = documents_delete_files_with_http_info(uuid, data, opts)
140
+ return data
141
+ end
142
+
143
+ #
144
+ # This is only for integration partners
145
+ # @param uuid
146
+ # @param data
147
+ # @param [Hash] opts the optional parameters
148
+ # @return [Array<(Document, Fixnum, Hash)>] Document data, response status code and response headers
149
+ def documents_delete_files_with_http_info(uuid, data, opts = {})
150
+ if @api_client.config.debugging
151
+ @api_client.config.logger.debug "Calling API: DocumentsApi.documents_delete_files ..."
152
+ end
153
+ # verify the required parameter 'uuid' is set
154
+ if @api_client.config.client_side_validation && uuid.nil?
155
+ fail ArgumentError, "Missing the required parameter 'uuid' when calling DocumentsApi.documents_delete_files"
156
+ end
157
+ # verify the required parameter 'data' is set
158
+ if @api_client.config.client_side_validation && data.nil?
159
+ fail ArgumentError, "Missing the required parameter 'data' when calling DocumentsApi.documents_delete_files"
160
+ end
161
+ # resource path
162
+ local_var_path = "/documents/{uuid}/delete_files/".sub('{' + 'uuid' + '}', uuid.to_s)
163
+
164
+ # query parameters
165
+ query_params = {}
166
+
167
+ # header parameters
168
+ header_params = {}
169
+ # HTTP header 'Accept' (if needed)
170
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
171
+ # HTTP header 'Content-Type'
172
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
173
+
174
+ # form parameters
175
+ form_params = {}
176
+
177
+ # http body (model)
178
+ post_body = @api_client.object_to_http_body(data)
179
+ auth_names = ['Token']
180
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
181
+ :header_params => header_params,
182
+ :query_params => query_params,
183
+ :form_params => form_params,
184
+ :body => post_body,
185
+ :auth_names => auth_names,
186
+ :return_type => 'Document')
187
+ if @api_client.config.debugging
188
+ @api_client.config.logger.debug "API called: DocumentsApi#documents_delete_files\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
189
+ end
190
+ return data, status_code, headers
191
+ end
192
+
193
+ #
194
+ #
195
+ # @param [Hash] opts the optional parameters
196
+ # @option opts [String] :external_id
197
+ # @option opts [String] :signrequest__who
198
+ # @option opts [String] :signrequest__from_email
199
+ # @option opts [String] :status
200
+ # @option opts [String] :user__email
201
+ # @option opts [String] :user__first_name
202
+ # @option opts [String] :user__last_name
203
+ # @option opts [String] :created
204
+ # @option opts [String] :modified
205
+ # @option opts [Integer] :page A page number within the paginated result set.
206
+ # @option opts [Integer] :limit Number of results to return per page.
207
+ # @return [InlineResponse2003]
208
+ def documents_list(opts = {})
209
+ data, _status_code, _headers = documents_list_with_http_info(opts)
210
+ return data
211
+ end
212
+
213
+ #
214
+ #
215
+ # @param [Hash] opts the optional parameters
216
+ # @option opts [String] :external_id
217
+ # @option opts [String] :signrequest__who
218
+ # @option opts [String] :signrequest__from_email
219
+ # @option opts [String] :status
220
+ # @option opts [String] :user__email
221
+ # @option opts [String] :user__first_name
222
+ # @option opts [String] :user__last_name
223
+ # @option opts [String] :created
224
+ # @option opts [String] :modified
225
+ # @option opts [Integer] :page A page number within the paginated result set.
226
+ # @option opts [Integer] :limit Number of results to return per page.
227
+ # @return [Array<(InlineResponse2003, Fixnum, Hash)>] InlineResponse2003 data, response status code and response headers
228
+ def documents_list_with_http_info(opts = {})
229
+ if @api_client.config.debugging
230
+ @api_client.config.logger.debug "Calling API: DocumentsApi.documents_list ..."
231
+ end
232
+ # resource path
233
+ local_var_path = "/documents/"
234
+
235
+ # query parameters
236
+ query_params = {}
237
+ query_params[:'external_id'] = opts[:'external_id'] if !opts[:'external_id'].nil?
238
+ query_params[:'signrequest__who'] = opts[:'signrequest__who'] if !opts[:'signrequest__who'].nil?
239
+ query_params[:'signrequest__from_email'] = opts[:'signrequest__from_email'] if !opts[:'signrequest__from_email'].nil?
240
+ query_params[:'status'] = opts[:'status'] if !opts[:'status'].nil?
241
+ query_params[:'user__email'] = opts[:'user__email'] if !opts[:'user__email'].nil?
242
+ query_params[:'user__first_name'] = opts[:'user__first_name'] if !opts[:'user__first_name'].nil?
243
+ query_params[:'user__last_name'] = opts[:'user__last_name'] if !opts[:'user__last_name'].nil?
244
+ query_params[:'created'] = opts[:'created'] if !opts[:'created'].nil?
245
+ query_params[:'modified'] = opts[:'modified'] if !opts[:'modified'].nil?
246
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
247
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
248
+
249
+ # header parameters
250
+ header_params = {}
251
+ # HTTP header 'Accept' (if needed)
252
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
253
+ # HTTP header 'Content-Type'
254
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
255
+
256
+ # form parameters
257
+ form_params = {}
258
+
259
+ # http body (model)
260
+ post_body = nil
261
+ auth_names = ['Token']
262
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
263
+ :header_params => header_params,
264
+ :query_params => query_params,
265
+ :form_params => form_params,
266
+ :body => post_body,
267
+ :auth_names => auth_names,
268
+ :return_type => 'InlineResponse2003')
269
+ if @api_client.config.debugging
270
+ @api_client.config.logger.debug "API called: DocumentsApi#documents_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
271
+ end
272
+ return data, status_code, headers
273
+ end
274
+
275
+ #
276
+ #
277
+ # @param uuid
278
+ # @param [Hash] opts the optional parameters
279
+ # @return [Document]
280
+ def documents_read(uuid, opts = {})
281
+ data, _status_code, _headers = documents_read_with_http_info(uuid, opts)
282
+ return data
283
+ end
284
+
285
+ #
286
+ #
287
+ # @param uuid
288
+ # @param [Hash] opts the optional parameters
289
+ # @return [Array<(Document, Fixnum, Hash)>] Document data, response status code and response headers
290
+ def documents_read_with_http_info(uuid, opts = {})
291
+ if @api_client.config.debugging
292
+ @api_client.config.logger.debug "Calling API: DocumentsApi.documents_read ..."
293
+ end
294
+ # verify the required parameter 'uuid' is set
295
+ if @api_client.config.client_side_validation && uuid.nil?
296
+ fail ArgumentError, "Missing the required parameter 'uuid' when calling DocumentsApi.documents_read"
297
+ end
298
+ # resource path
299
+ local_var_path = "/documents/{uuid}/".sub('{' + 'uuid' + '}', uuid.to_s)
300
+
301
+ # query parameters
302
+ query_params = {}
303
+
304
+ # header parameters
305
+ header_params = {}
306
+ # HTTP header 'Accept' (if needed)
307
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
308
+ # HTTP header 'Content-Type'
309
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
310
+
311
+ # form parameters
312
+ form_params = {}
313
+
314
+ # http body (model)
315
+ post_body = nil
316
+ auth_names = ['Token']
317
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
318
+ :header_params => header_params,
319
+ :query_params => query_params,
320
+ :form_params => form_params,
321
+ :body => post_body,
322
+ :auth_names => auth_names,
323
+ :return_type => 'Document')
324
+ if @api_client.config.debugging
325
+ @api_client.config.logger.debug "API called: DocumentsApi#documents_read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
326
+ end
327
+ return data, status_code, headers
328
+ end
329
+ end
330
+ end
@@ -0,0 +1,133 @@
1
+ =begin
2
+ #SignRequest API
3
+
4
+ #API for SignRequest.com
5
+
6
+ OpenAPI spec version: v1
7
+ Contact: tech-support@signrequest.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.3.1
10
+
11
+ =end
12
+
13
+ require "uri"
14
+
15
+ module SignRequestClient
16
+ class DocumentsSearchApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+
23
+ #
24
+ # ## Search interface for fast (autocomplete) searching of documents. This can be useful to have your users search for a document in your interface. Document names are tokenized on whitespace, hyphens and underscores to also match partial document names. *Normal search:* - ?**q**={{query}} *Autocomplete search:* - ?**autocomplete**={{partial query}} *Search in document name:* - ?**name**={{query}} *Available (extra) filters:* - ?**subdomain**={{ team_subdomain }} or use this endpoint with team_subdomain.signrequest.com (when not provided only personal documents are shown) - ?**signer_emails**={{ signer@email.com }} (will filter documents that an email needed to sign/approve) - ?**status**={{ si }} - ?**who**={{ mo }} To include multiple values for a filter field separate the values with a pipe (|). For example to only search for completed documents use **status=se|vi** (sent and viewed). *Pagination:* - ?**page**={{ page_number: default 1 }} - ?**limit**={{ limit results: default 10, max 100 }} *Format:* By default json is returned, to export data as csv or xls use the format parameter. - ?**format**=csv - ?**format**=xls For csv and xls the data can also be exported with each signer on a separate row. In this mode also the signer inputs that have an *external_id* specified on a tag will be exported. All external_id's found will be exported as columns. To use this mode add the **signer_data** parameter. - ?**format**=csv&**signer_data**=1 - ?**format**=xls&**signer_data**=1 Note that all documents are only ordered by **created** (newest first) when **q**, **autocomplete** or **name** are not used, else they are ordered by the strenght of the match.
25
+ # @param [Hash] opts the optional parameters
26
+ # @option opts [Integer] :page A page number within the paginated result set.
27
+ # @option opts [Integer] :limit Number of results to return per page.
28
+ # @return [InlineResponse2002]
29
+ def documents_search_list(opts = {})
30
+ data, _status_code, _headers = documents_search_list_with_http_info(opts)
31
+ return data
32
+ end
33
+
34
+ #
35
+ # ## Search interface for fast (autocomplete) searching of documents. This can be useful to have your users search for a document in your interface. Document names are tokenized on whitespace, hyphens and underscores to also match partial document names. *Normal search:* - ?**q**&#x3D;{{query}} *Autocomplete search:* - ?**autocomplete**&#x3D;{{partial query}} *Search in document name:* - ?**name**&#x3D;{{query}} *Available (extra) filters:* - ?**subdomain**&#x3D;{{ team_subdomain }} or use this endpoint with team_subdomain.signrequest.com (when not provided only personal documents are shown) - ?**signer_emails**&#x3D;{{ signer@email.com }} (will filter documents that an email needed to sign/approve) - ?**status**&#x3D;{{ si }} - ?**who**&#x3D;{{ mo }} To include multiple values for a filter field separate the values with a pipe (|). For example to only search for completed documents use **status&#x3D;se|vi** (sent and viewed). *Pagination:* - ?**page**&#x3D;{{ page_number: default 1 }} - ?**limit**&#x3D;{{ limit results: default 10, max 100 }} *Format:* By default json is returned, to export data as csv or xls use the format parameter. - ?**format**&#x3D;csv - ?**format**&#x3D;xls For csv and xls the data can also be exported with each signer on a separate row. In this mode also the signer inputs that have an *external_id* specified on a tag will be exported. All external_id&#39;s found will be exported as columns. To use this mode add the **signer_data** parameter. - ?**format**&#x3D;csv&amp;**signer_data**&#x3D;1 - ?**format**&#x3D;xls&amp;**signer_data**&#x3D;1 Note that all documents are only ordered by **created** (newest first) when **q**, **autocomplete** or **name** are not used, else they are ordered by the strenght of the match.
36
+ # @param [Hash] opts the optional parameters
37
+ # @option opts [Integer] :page A page number within the paginated result set.
38
+ # @option opts [Integer] :limit Number of results to return per page.
39
+ # @return [Array<(InlineResponse2002, Fixnum, Hash)>] InlineResponse2002 data, response status code and response headers
40
+ def documents_search_list_with_http_info(opts = {})
41
+ if @api_client.config.debugging
42
+ @api_client.config.logger.debug "Calling API: DocumentsSearchApi.documents_search_list ..."
43
+ end
44
+ # resource path
45
+ local_var_path = "/documents-search/"
46
+
47
+ # query parameters
48
+ query_params = {}
49
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
50
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
51
+
52
+ # header parameters
53
+ header_params = {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'text/csv', 'application/vnd.ms-excel'])
56
+ # HTTP header 'Content-Type'
57
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
58
+
59
+ # form parameters
60
+ form_params = {}
61
+
62
+ # http body (model)
63
+ post_body = nil
64
+ auth_names = ['Token']
65
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
66
+ :header_params => header_params,
67
+ :query_params => query_params,
68
+ :form_params => form_params,
69
+ :body => post_body,
70
+ :auth_names => auth_names,
71
+ :return_type => 'InlineResponse2002')
72
+ if @api_client.config.debugging
73
+ @api_client.config.logger.debug "API called: DocumentsSearchApi#documents_search_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
+ end
75
+ return data, status_code, headers
76
+ end
77
+
78
+ #
79
+ # ## Search interface for fast (autocomplete) searching of documents. This can be useful to have your users search for a document in your interface. Document names are tokenized on whitespace, hyphens and underscores to also match partial document names. *Normal search:* - ?**q**={{query}} *Autocomplete search:* - ?**autocomplete**={{partial query}} *Search in document name:* - ?**name**={{query}} *Available (extra) filters:* - ?**subdomain**={{ team_subdomain }} or use this endpoint with team_subdomain.signrequest.com (when not provided only personal documents are shown) - ?**signer_emails**={{ signer@email.com }} (will filter documents that an email needed to sign/approve) - ?**status**={{ si }} - ?**who**={{ mo }} To include multiple values for a filter field separate the values with a pipe (|). For example to only search for completed documents use **status=se|vi** (sent and viewed). *Pagination:* - ?**page**={{ page_number: default 1 }} - ?**limit**={{ limit results: default 10, max 100 }} *Format:* By default json is returned, to export data as csv or xls use the format parameter. - ?**format**=csv - ?**format**=xls For csv and xls the data can also be exported with each signer on a separate row. In this mode also the signer inputs that have an *external_id* specified on a tag will be exported. All external_id's found will be exported as columns. To use this mode add the **signer_data** parameter. - ?**format**=csv&**signer_data**=1 - ?**format**=xls&**signer_data**=1 Note that all documents are only ordered by **created** (newest first) when **q**, **autocomplete** or **name** are not used, else they are ordered by the strenght of the match.
80
+ # @param id
81
+ # @param [Hash] opts the optional parameters
82
+ # @return [DocumentSearch]
83
+ def documents_search_read(id, opts = {})
84
+ data, _status_code, _headers = documents_search_read_with_http_info(id, opts)
85
+ return data
86
+ end
87
+
88
+ #
89
+ # ## Search interface for fast (autocomplete) searching of documents. This can be useful to have your users search for a document in your interface. Document names are tokenized on whitespace, hyphens and underscores to also match partial document names. *Normal search:* - ?**q**&#x3D;{{query}} *Autocomplete search:* - ?**autocomplete**&#x3D;{{partial query}} *Search in document name:* - ?**name**&#x3D;{{query}} *Available (extra) filters:* - ?**subdomain**&#x3D;{{ team_subdomain }} or use this endpoint with team_subdomain.signrequest.com (when not provided only personal documents are shown) - ?**signer_emails**&#x3D;{{ signer@email.com }} (will filter documents that an email needed to sign/approve) - ?**status**&#x3D;{{ si }} - ?**who**&#x3D;{{ mo }} To include multiple values for a filter field separate the values with a pipe (|). For example to only search for completed documents use **status&#x3D;se|vi** (sent and viewed). *Pagination:* - ?**page**&#x3D;{{ page_number: default 1 }} - ?**limit**&#x3D;{{ limit results: default 10, max 100 }} *Format:* By default json is returned, to export data as csv or xls use the format parameter. - ?**format**&#x3D;csv - ?**format**&#x3D;xls For csv and xls the data can also be exported with each signer on a separate row. In this mode also the signer inputs that have an *external_id* specified on a tag will be exported. All external_id&#39;s found will be exported as columns. To use this mode add the **signer_data** parameter. - ?**format**&#x3D;csv&amp;**signer_data**&#x3D;1 - ?**format**&#x3D;xls&amp;**signer_data**&#x3D;1 Note that all documents are only ordered by **created** (newest first) when **q**, **autocomplete** or **name** are not used, else they are ordered by the strenght of the match.
90
+ # @param id
91
+ # @param [Hash] opts the optional parameters
92
+ # @return [Array<(DocumentSearch, Fixnum, Hash)>] DocumentSearch data, response status code and response headers
93
+ def documents_search_read_with_http_info(id, opts = {})
94
+ if @api_client.config.debugging
95
+ @api_client.config.logger.debug "Calling API: DocumentsSearchApi.documents_search_read ..."
96
+ end
97
+ # verify the required parameter 'id' is set
98
+ if @api_client.config.client_side_validation && id.nil?
99
+ fail ArgumentError, "Missing the required parameter 'id' when calling DocumentsSearchApi.documents_search_read"
100
+ end
101
+ # resource path
102
+ local_var_path = "/documents-search/{id}/".sub('{' + 'id' + '}', id.to_s)
103
+
104
+ # query parameters
105
+ query_params = {}
106
+
107
+ # header parameters
108
+ header_params = {}
109
+ # HTTP header 'Accept' (if needed)
110
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'text/csv', 'application/vnd.ms-excel'])
111
+ # HTTP header 'Content-Type'
112
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
113
+
114
+ # form parameters
115
+ form_params = {}
116
+
117
+ # http body (model)
118
+ post_body = nil
119
+ auth_names = ['Token']
120
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
121
+ :header_params => header_params,
122
+ :query_params => query_params,
123
+ :form_params => form_params,
124
+ :body => post_body,
125
+ :auth_names => auth_names,
126
+ :return_type => 'DocumentSearch')
127
+ if @api_client.config.debugging
128
+ @api_client.config.logger.debug "API called: DocumentsSearchApi#documents_search_read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
129
+ end
130
+ return data, status_code, headers
131
+ end
132
+ end
133
+ end