crisp-api 1.1.10 → 1.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/EXAMPLES.md +10 -0
- data/README.md +16 -2
- data/crisp-api.gemspec +1 -1
- data/lib/crisp-api.rb +1 -1
- data/lib/resources/website.rb +4 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b0a0c4760c778003a2678bf91aeffddca2ff537a6a10d95e877dc5fcd7db9a0e
|
4
|
+
data.tar.gz: e95dd60c4c6af472c0bfdee29c0d99ae70d7698be4a5ec4fd624cd3b7bfc709d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 86ab7ada912dbe4926c5a27bbc644cb9cd93c666c80089aa78eb6966d98c1608623d72144b2dab1aa52c272fcbef2dcaf180477aa4c3b6145a55d1ebfaa25002
|
7
|
+
data.tar.gz: 1bb9275844af933a6beea51e75eda47118b2e49b5836f1f4f8586ec94131ff4aa3ab925cf4e0ddf1ae2cc3ab4c7fec7e3c81a612c83bfc42431fe8bfbd478881
|
data/EXAMPLES.md
CHANGED
@@ -221,6 +221,16 @@ client.website.list_conversation_events(website_id, session_id, page_number);
|
|
221
221
|
|
222
222
|
=========================
|
223
223
|
|
224
|
+
https://docs.crisp.chat/references/rest-api/v1/#list-conversation-files
|
225
|
+
|
226
|
+
website_id = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc"
|
227
|
+
session_id = "session_700c65e1-85e2-465a-b9ac-ecb5ec2c9881"
|
228
|
+
page_number = 1
|
229
|
+
|
230
|
+
client.website.list_conversation_files(website_id, session_id, page_number);
|
231
|
+
|
232
|
+
=========================
|
233
|
+
|
224
234
|
https://docs.crisp.chat/references/rest-api/v1/#get-conversation-state
|
225
235
|
|
226
236
|
website_id = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc"
|
data/README.md
CHANGED
@@ -6,7 +6,7 @@ The Crisp API Ruby wrapper. Authenticate, send messages, fetch conversations, ac
|
|
6
6
|
|
7
7
|
Copyright 2023 Crisp IM SAS. See LICENSE for copying information.
|
8
8
|
|
9
|
-
* **📝 Implements**: [REST API Reference (V1)](https://docs.crisp.chat/references/rest-api/v1/) at revision:
|
9
|
+
* **📝 Implements**: [REST API Reference (V1)](https://docs.crisp.chat/references/rest-api/v1/) at revision: 16/01/2023
|
10
10
|
* **😘 Maintainer**: [@valeriansaliou](https://github.com/valeriansaliou), [@eliottvincent](https://github.com/eliottvincent)
|
11
11
|
|
12
12
|
## Usage
|
@@ -16,7 +16,7 @@ You may follow the [REST API Quickstart](https://docs.crisp.chat/guides/rest-api
|
|
16
16
|
Add the library to your `Gemfile`:
|
17
17
|
|
18
18
|
```bash
|
19
|
-
gem "crisp-api", "~> 1.1.
|
19
|
+
gem "crisp-api", "~> 1.1.11"
|
20
20
|
```
|
21
21
|
|
22
22
|
Then, import it:
|
@@ -387,6 +387,20 @@ client.website.send_message_in_conversation(
|
|
387
387
|
```
|
388
388
|
</details>
|
389
389
|
|
390
|
+
* **List Conversation Files** [`user`, `plugin`]: [Reference](https://docs.crisp.chat/references/rest-api/v1/#list-conversation-files)
|
391
|
+
* `client.website.list_conversation_files(website_id, session_id, page_number)`
|
392
|
+
* <details>
|
393
|
+
<summary>See Example</summary>
|
394
|
+
|
395
|
+
```ruby
|
396
|
+
website_id = "8c842203-7ed8-4e29-a608-7cf78a7d2fcc"
|
397
|
+
session_id = "session_700c65e1-85e2-465a-b9ac-ecb5ec2c9881"
|
398
|
+
page_number = 1
|
399
|
+
|
400
|
+
client.website.list_conversation_files(website_id, session_id, page_number);
|
401
|
+
```
|
402
|
+
</details>
|
403
|
+
|
390
404
|
* **Get Conversation State** [`user`, `plugin`]: [Reference](https://docs.crisp.chat/references/rest-api/v1/#get-conversation-state)
|
391
405
|
* `client.website.get_conversation_state(website_id, session_id)`
|
392
406
|
* <details>
|
data/crisp-api.gemspec
CHANGED
data/lib/crisp-api.rb
CHANGED
data/lib/resources/website.rb
CHANGED
@@ -192,6 +192,10 @@ module Crisp
|
|
192
192
|
return @parent.get(self._url_conversation(website_id, session_id, "/events/%d" % page_number))
|
193
193
|
end
|
194
194
|
|
195
|
+
def list_conversation_files(website_id, session_id, page_number)
|
196
|
+
return @parent.get(self._url_conversation(website_id, session_id, "/files/%d" % page_number))
|
197
|
+
end
|
198
|
+
|
195
199
|
def get_conversation_state(website_id, session_id)
|
196
200
|
return @parent.get(self._url_conversation(website_id, session_id, "/state"))
|
197
201
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: crisp-api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Valerian Saliou
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-01-
|
11
|
+
date: 2023-01-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rest-client
|