cirro-ruby-client 2.4.0 → 2.5.1
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/Gemfile.lock +1 -1
- data/README.md +8 -2
- data/lib/cirro_io/client/version.rb +1 -1
- data/lib/cirro_io_v2/client.rb +5 -0
- data/lib/cirro_io_v2/resources/epam_heroes/badges.rb +14 -0
- data/lib/cirro_io_v2/resources/gig.rb +5 -0
- data/lib/cirro_io_v2/responses/responses.rb +4 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 176d48dd4fecf3e1f62e050883a95583edc73755f097ec2818b264ec111ed0f3
|
4
|
+
data.tar.gz: cf94dda3d2179e29fed9d9cf9ca9753994cf169afab62d167b38d64c87ca68e7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 83c920d83ec30f7d4a539a88df4d214493754269694cff03507bb9e4686fbb81792b8e7de6a1fd0266e78c00f8f7b17fee1d2db03a711db2c8e4a2d7c9473f0c
|
7
|
+
data.tar.gz: cea607da619df9f5b32c29418d39c4aaf2526c5377289ec46d707fc37e8e6cb5c8a0b0da584d052cf093869379e9b525fac852df89f216c408f1a1eb70cf20da
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -150,6 +150,12 @@ client.User.create
|
|
150
150
|
```
|
151
151
|
|
152
152
|
## Gig
|
153
|
+
### Find a gig
|
154
|
+
|
155
|
+
```ruby
|
156
|
+
client.Gig.find(ID)
|
157
|
+
# => Gig object
|
158
|
+
```
|
153
159
|
### Create a gig
|
154
160
|
|
155
161
|
```ruby
|
@@ -385,13 +391,13 @@ client.NotificationTemplate.update(
|
|
385
391
|
"subject": "New Bug Comment",
|
386
392
|
"body": "Hello {{recipient_first_name}}, you got {{pluralize count, 'new comment', 'new comments'}}"
|
387
393
|
)
|
388
|
-
```
|
394
|
+
```
|
389
395
|
|
390
396
|
### Delete a notification template
|
391
397
|
|
392
398
|
```ruby
|
393
399
|
client.NotificationTemplate.delete('1')
|
394
|
-
```
|
400
|
+
```
|
395
401
|
## Notifcation Topic Preference
|
396
402
|
### List all
|
397
403
|
|
data/lib/cirro_io_v2/client.rb
CHANGED
@@ -13,6 +13,7 @@ require 'cirro_io_v2/resources/payout'
|
|
13
13
|
require 'cirro_io_v2/resources/gig_invitation'
|
14
14
|
require 'cirro_io_v2/resources/user'
|
15
15
|
require 'cirro_io_v2/resources/space_invitation'
|
16
|
+
require 'cirro_io_v2/resources/epam_heroes/badges'
|
16
17
|
|
17
18
|
require 'cirro_io_v2/responses/base'
|
18
19
|
require 'cirro_io_v2/responses/responses'
|
@@ -121,6 +122,10 @@ module CirroIOV2
|
|
121
122
|
Resources::NotificationTemplate.new(self)
|
122
123
|
end
|
123
124
|
|
125
|
+
def EpamHeroesBadges
|
126
|
+
Resources::EpamHeroes::Badges.new(self)
|
127
|
+
end
|
128
|
+
|
124
129
|
# rubocop:enable Naming/MethodName
|
125
130
|
end
|
126
131
|
end
|
@@ -0,0 +1,14 @@
|
|
1
|
+
module CirroIOV2
|
2
|
+
module Resources
|
3
|
+
module EpamHeroes
|
4
|
+
class Badges < Base
|
5
|
+
ENDPOINT_PATH = 'epam_heroes/badges'.freeze
|
6
|
+
|
7
|
+
def create(params)
|
8
|
+
response = client.request_client.request(:post, ENDPOINT_PATH, body: params)
|
9
|
+
Responses::EpamHeroesBadgeResponse.new(response.body)
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
@@ -1,6 +1,11 @@
|
|
1
1
|
module CirroIOV2
|
2
2
|
module Resources
|
3
3
|
class Gig < Base
|
4
|
+
def find(id)
|
5
|
+
response = client.request_client.request(:get, [resource_root, id].join('/'))
|
6
|
+
Responses::GigResponse.new(response.body)
|
7
|
+
end
|
8
|
+
|
4
9
|
def create(params)
|
5
10
|
response = client.request_client.request(:post, resource_root, body: params)
|
6
11
|
Responses::GigResponse.new(response.body)
|
@@ -129,6 +129,10 @@ module CirroIOV2
|
|
129
129
|
include Base
|
130
130
|
end
|
131
131
|
|
132
|
+
EpamHeroesBadgeResponse = Struct.new(:content, :refs, :paging, :hasMoreResults) do
|
133
|
+
include Base
|
134
|
+
end
|
135
|
+
|
132
136
|
# cover the list responses
|
133
137
|
def self.const_missing(name)
|
134
138
|
return const_get(name) if const_defined? name
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cirro-ruby-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cirro Dev Team
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-12-
|
11
|
+
date: 2022-12-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -127,6 +127,7 @@ files:
|
|
127
127
|
- lib/cirro_io_v2/request_clients/base.rb
|
128
128
|
- lib/cirro_io_v2/request_clients/jwt.rb
|
129
129
|
- lib/cirro_io_v2/resources/base.rb
|
130
|
+
- lib/cirro_io_v2/resources/epam_heroes/badges.rb
|
130
131
|
- lib/cirro_io_v2/resources/gig.rb
|
131
132
|
- lib/cirro_io_v2/resources/gig_invitation.rb
|
132
133
|
- lib/cirro_io_v2/resources/gig_result.rb
|