mxhero-api 0.1.11 → 0.1.12
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/communication.rb +35 -0
- data/lib/groups.rb +178 -0
- data/lib/mxhero-api.rb +288 -312
- data/lib/urls.rb +19 -0
- data/mxhero-api.gemspec +4 -4
- data/test/fixtures/api/account_properties.yml +12 -13
- data/test/fixtures/api/account_properties_not_found.yml +9 -9
- data/test/fixtures/api/accounts.yml +39 -0
- data/test/fixtures/api/accounts_filtered.yml +57 -42
- data/test/fixtures/api/accounts_from_domain.yml +10 -10
- data/test/fixtures/api/accounts_from_domain_paginated.yml +10 -10
- data/test/fixtures/api/accounts_without_group.yml +75 -0
- data/test/fixtures/api/add_an_inexistent_account_to_group.yml +39 -0
- data/test/fixtures/api/add_and_remove_account.yml +219 -0
- data/test/fixtures/api/all_groups.yml +39 -0
- data/test/fixtures/api/create_rule_for_domain.yml +95 -21
- data/test/fixtures/api/delete_group.yml +75 -0
- data/test/fixtures/api/delete_rule.yml +21 -61
- data/test/fixtures/api/domain_by_id.yml +10 -10
- data/test/fixtures/api/domain_by_id_not_found.yml +9 -9
- data/test/fixtures/api/domain_rule.yml +62 -76
- data/test/fixtures/api/domains.yml +10 -10
- data/test/fixtures/api/remove_account_from_group_twice.yml +150 -0
- data/test/fixtures/api/remove_inexistente_account_from_group.yml +39 -0
- data/test/fixtures/api/rules_for_domain.yml +11 -57
- data/test/fixtures/api/rules_for_domain_by_component.yml +6 -8
- data/test/fixtures/api/save_group.yml +119 -0
- data/test/fixtures/api/update_account_properties.yml +35 -33
- data/test/fixtures/api/update_rule.yml +35 -76
- data/test/helper.rb +1 -1
- data/test/test_groups.rb +104 -0
- data/test/test_mxhero_api.rb +49 -27
- metadata +26 -7
- data/test/fixtures/api/create_rule_alredy_exist.yml +0 -81
- data/test/fixtures/api/create_rule_success.yml +0 -41
data/lib/urls.rb
ADDED
data/mxhero-api.gemspec
CHANGED
@@ -2,20 +2,20 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = "mxhero-api"
|
5
|
-
s.version = "0.1.
|
5
|
+
s.version = "0.1.12"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Maximiliano Dello Russo", "Juan Pablo Royo", "mxHero"]
|
9
|
-
s.date = "2013-09-
|
9
|
+
s.date = "2013-09-18"
|
10
10
|
s.description = "A gem to provide easy access to the API of MxHero platform (http://www.mxhero.com/)"
|
11
11
|
s.email = ["maxidr@mxhero.com", "juanpablo.royo@gmail.com", "mxhero@mxhero.com"]
|
12
|
-
s.files = [".gitignore", ".rvmrc", "Gemfile", "LICENSE.txt", "README.md", "Rakefile", "VERSION", "lib/mxhero-api.rb", "mxhero-api.gemspec", "test/fixtures/api/account_properties.yml", "test/fixtures/api/account_properties_not_found.yml", "test/fixtures/api/accounts_filtered.yml", "test/fixtures/api/accounts_from_domain.yml", "test/fixtures/api/accounts_from_domain_paginated.yml", "test/fixtures/api/
|
12
|
+
s.files = [".gitignore", ".rvmrc", "Gemfile", "LICENSE.txt", "README.md", "Rakefile", "VERSION", "lib/communication.rb", "lib/groups.rb", "lib/mxhero-api.rb", "lib/urls.rb", "mxhero-api.gemspec", "test/fixtures/api/account_properties.yml", "test/fixtures/api/account_properties_not_found.yml", "test/fixtures/api/accounts.yml", "test/fixtures/api/accounts_filtered.yml", "test/fixtures/api/accounts_from_domain.yml", "test/fixtures/api/accounts_from_domain_paginated.yml", "test/fixtures/api/accounts_without_group.yml", "test/fixtures/api/add_an_inexistent_account_to_group.yml", "test/fixtures/api/add_and_remove_account.yml", "test/fixtures/api/all_groups.yml", "test/fixtures/api/create_rule_for_domain.yml", "test/fixtures/api/delete_group.yml", "test/fixtures/api/delete_rule.yml", "test/fixtures/api/domain_by_id.yml", "test/fixtures/api/domain_by_id_not_found.yml", "test/fixtures/api/domain_rule.yml", "test/fixtures/api/domains.yml", "test/fixtures/api/remove_account_from_group_twice.yml", "test/fixtures/api/remove_inexistente_account_from_group.yml", "test/fixtures/api/rules_for_domain.yml", "test/fixtures/api/rules_for_domain_by_component.yml", "test/fixtures/api/save_group.yml", "test/fixtures/api/update_account_properties.yml", "test/fixtures/api/update_rule.yml", "test/helper.rb", "test/test_groups.rb", "test/test_mxhero_api.rb", "test/test_mxhero_api_response.rb"]
|
13
13
|
s.homepage = "http://github.com/mxhero/mxhero-api"
|
14
14
|
s.licenses = ["GPL-3"]
|
15
15
|
s.require_paths = ["lib"]
|
16
16
|
s.rubygems_version = "1.8.25"
|
17
17
|
s.summary = "A MxHero API client for ruby"
|
18
|
-
s.test_files = ["test/fixtures/api/account_properties.yml", "test/fixtures/api/account_properties_not_found.yml", "test/fixtures/api/accounts_filtered.yml", "test/fixtures/api/accounts_from_domain.yml", "test/fixtures/api/accounts_from_domain_paginated.yml", "test/fixtures/api/
|
18
|
+
s.test_files = ["test/fixtures/api/account_properties.yml", "test/fixtures/api/account_properties_not_found.yml", "test/fixtures/api/accounts.yml", "test/fixtures/api/accounts_filtered.yml", "test/fixtures/api/accounts_from_domain.yml", "test/fixtures/api/accounts_from_domain_paginated.yml", "test/fixtures/api/accounts_without_group.yml", "test/fixtures/api/add_an_inexistent_account_to_group.yml", "test/fixtures/api/add_and_remove_account.yml", "test/fixtures/api/all_groups.yml", "test/fixtures/api/create_rule_for_domain.yml", "test/fixtures/api/delete_group.yml", "test/fixtures/api/delete_rule.yml", "test/fixtures/api/domain_by_id.yml", "test/fixtures/api/domain_by_id_not_found.yml", "test/fixtures/api/domain_rule.yml", "test/fixtures/api/domains.yml", "test/fixtures/api/remove_account_from_group_twice.yml", "test/fixtures/api/remove_inexistente_account_from_group.yml", "test/fixtures/api/rules_for_domain.yml", "test/fixtures/api/rules_for_domain_by_component.yml", "test/fixtures/api/save_group.yml", "test/fixtures/api/update_account_properties.yml", "test/fixtures/api/update_rule.yml", "test/helper.rb", "test/test_groups.rb", "test/test_mxhero_api.rb", "test/test_mxhero_api_response.rb"]
|
19
19
|
|
20
20
|
if s.respond_to? :specification_version then
|
21
21
|
s.specification_version = 3
|
@@ -2,7 +2,7 @@
|
|
2
2
|
http_interactions:
|
3
3
|
- request:
|
4
4
|
method: get
|
5
|
-
uri: http://admin:password@
|
5
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/accounts/test/properties
|
6
6
|
body:
|
7
7
|
encoding: US-ASCII
|
8
8
|
string: ''
|
@@ -19,24 +19,23 @@ http_interactions:
|
|
19
19
|
message: !binary |-
|
20
20
|
T0s=
|
21
21
|
headers:
|
22
|
+
!binary "RGF0ZQ==":
|
23
|
+
- !binary |-
|
24
|
+
VGh1LCAxMiBTZXAgMjAxMyAyMToyMTowNyBHTVQ=
|
22
25
|
!binary "U2VydmVy":
|
23
26
|
- !binary |-
|
24
|
-
|
27
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
28
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
29
|
+
- !binary |-
|
30
|
+
MzM3
|
25
31
|
!binary "Q29udGVudC1UeXBl":
|
26
32
|
- !binary |-
|
27
33
|
YXBwbGljYXRpb24vanNvbg==
|
28
|
-
!binary "VHJhbnNmZXItRW5jb2Rpbmc=":
|
29
|
-
- !binary |-
|
30
|
-
Y2h1bmtlZA==
|
31
|
-
!binary "RGF0ZQ==":
|
32
|
-
- !binary |-
|
33
|
-
RnJpLCAwOSBBdWcgMjAxMyAxNjoyMjo1MCBHTVQ=
|
34
34
|
body:
|
35
35
|
encoding: US-ASCII
|
36
|
-
string: ! '[{"name":"email","value":"
|
37
|
-
|
38
|
-
|
39
|
-
2"},{"name":"opt3","value":""},{"name":"telephone","value":"3333-3333"}]'
|
36
|
+
string: ! '[{"name":"email","value":""},{"name":"fax","value":null},{"name":"lastname","value":"
|
37
|
+
CHANGED CHANGED CHANGED CHANGED CHANGED"},{"name":"mobile","value":""},{"name":"name","value":"
|
38
|
+
CHANGED CHANGED CHANGED CHANGED CHANGED"},{"name":"opt1","value":""},{"name":"opt2","value":""},{"name":"opt3","value":""},{"name":"telephone","value":""}]'
|
40
39
|
http_version:
|
41
|
-
recorded_at:
|
40
|
+
recorded_at: Thu, 12 Sep 2013 21:21:06 GMT
|
42
41
|
recorded_with: VCR 2.5.0
|
@@ -2,7 +2,7 @@
|
|
2
2
|
http_interactions:
|
3
3
|
- request:
|
4
4
|
method: get
|
5
|
-
uri: http://admin:password@
|
5
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/accounts/xxxxx/properties
|
6
6
|
body:
|
7
7
|
encoding: US-ASCII
|
8
8
|
string: ''
|
@@ -19,21 +19,21 @@ http_interactions:
|
|
19
19
|
message: !binary |-
|
20
20
|
Tm90IEZvdW5k
|
21
21
|
headers:
|
22
|
+
!binary "RGF0ZQ==":
|
23
|
+
- !binary |-
|
24
|
+
VGh1LCAxMiBTZXAgMjAxMyAyMToyMToxNCBHTVQ=
|
22
25
|
!binary "U2VydmVy":
|
23
26
|
- !binary |-
|
24
|
-
|
27
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
28
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
29
|
+
- !binary |-
|
30
|
+
MTUw
|
25
31
|
!binary "Q29udGVudC1UeXBl":
|
26
32
|
- !binary |-
|
27
33
|
YXBwbGljYXRpb24vanNvbg==
|
28
|
-
!binary "VHJhbnNmZXItRW5jb2Rpbmc=":
|
29
|
-
- !binary |-
|
30
|
-
Y2h1bmtlZA==
|
31
|
-
!binary "RGF0ZQ==":
|
32
|
-
- !binary |-
|
33
|
-
RnJpLCAwOSBBdWcgMjAxMyAxNjo0NzoxMyBHTVQ=
|
34
34
|
body:
|
35
35
|
encoding: US-ASCII
|
36
36
|
string: ! '{"status":404,"code":404,"message":"domain.account.not.found","developerMessage":"domain.account.not.found","moreInfoUrl":"mailto:support@mxhero.com"}'
|
37
37
|
http_version:
|
38
|
-
recorded_at:
|
38
|
+
recorded_at: Thu, 12 Sep 2013 21:21:14 GMT
|
39
39
|
recorded_with: VCR 2.5.0
|
@@ -0,0 +1,39 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/groups/development/accounts
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json
|
12
|
+
Content-Type:
|
13
|
+
- application/json
|
14
|
+
Authorization:
|
15
|
+
- Basic YWRtaW46cGFzc3dvcmQ=
|
16
|
+
response:
|
17
|
+
status:
|
18
|
+
code: 200
|
19
|
+
message: !binary |-
|
20
|
+
T0s=
|
21
|
+
headers:
|
22
|
+
!binary "RGF0ZQ==":
|
23
|
+
- !binary |-
|
24
|
+
RnJpLCAxMyBTZXAgMjAxMyAxNjoxMzoyOSBHTVQ=
|
25
|
+
!binary "U2VydmVy":
|
26
|
+
- !binary |-
|
27
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
28
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
29
|
+
- !binary |-
|
30
|
+
Mjg3
|
31
|
+
!binary "Q29udGVudC1UeXBl":
|
32
|
+
- !binary |-
|
33
|
+
YXBwbGljYXRpb24vanNvbg==
|
34
|
+
body:
|
35
|
+
encoding: US-ASCII
|
36
|
+
string: ! '{"elements":[{"account":"agent.smith","domain":"tesla.com","createdDate":1378759089000,"updatedDate":1379077074000,"group":"development","aliases":[{"name":"agent.smith","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":1,"totalPages":1,"actualPage":1}'
|
37
|
+
http_version:
|
38
|
+
recorded_at: Fri, 13 Sep 2013 16:13:27 GMT
|
39
|
+
recorded_with: VCR 2.5.0
|
@@ -2,9 +2,9 @@
|
|
2
2
|
http_interactions:
|
3
3
|
- request:
|
4
4
|
method: get
|
5
|
-
uri: http://admin:password@
|
5
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/accounts?account=test&limit=&offset=
|
6
6
|
body:
|
7
|
-
encoding:
|
7
|
+
encoding: US-ASCII
|
8
8
|
string: ''
|
9
9
|
headers:
|
10
10
|
Accept:
|
@@ -16,26 +16,31 @@ http_interactions:
|
|
16
16
|
response:
|
17
17
|
status:
|
18
18
|
code: 200
|
19
|
-
message:
|
19
|
+
message: !binary |-
|
20
|
+
T0s=
|
20
21
|
headers:
|
21
|
-
|
22
|
-
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
-
|
22
|
+
!binary "RGF0ZQ==":
|
23
|
+
- !binary |-
|
24
|
+
RnJpLCAxMyBTZXAgMjAxMyAyMDozNjowMiBHTVQ=
|
25
|
+
!binary "U2VydmVy":
|
26
|
+
- !binary |-
|
27
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
28
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
29
|
+
- !binary |-
|
30
|
+
Njc4
|
31
|
+
!binary "Q29udGVudC1UeXBl":
|
32
|
+
- !binary |-
|
33
|
+
YXBwbGljYXRpb24vanNvbg==
|
29
34
|
body:
|
30
|
-
encoding:
|
31
|
-
string: '{"elements":[{"account":"
|
35
|
+
encoding: US-ASCII
|
36
|
+
string: ! '{"elements":[{"account":"test","domain":"tesla.com","createdDate":1379013802000,"updatedDate":1379077065000,"group":"test","aliases":[{"name":"test","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"test1","domain":"tesla.com","createdDate":1378759068000,"updatedDate":1379077065000,"group":"test","aliases":[{"name":"test1","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"test2","domain":"tesla.com","createdDate":1378759074000,"updatedDate":1379077065000,"group":"test","aliases":[{"name":"test2","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":3,"totalPages":1,"actualPage":1}'
|
32
37
|
http_version:
|
33
|
-
recorded_at:
|
38
|
+
recorded_at: Fri, 13 Sep 2013 20:36:02 GMT
|
34
39
|
- request:
|
35
40
|
method: get
|
36
|
-
uri: http://admin:password@
|
41
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/accounts?account=john.doe&limit=&offset=
|
37
42
|
body:
|
38
|
-
encoding:
|
43
|
+
encoding: US-ASCII
|
39
44
|
string: ''
|
40
45
|
headers:
|
41
46
|
Accept:
|
@@ -47,26 +52,31 @@ http_interactions:
|
|
47
52
|
response:
|
48
53
|
status:
|
49
54
|
code: 200
|
50
|
-
message:
|
55
|
+
message: !binary |-
|
56
|
+
T0s=
|
51
57
|
headers:
|
52
|
-
|
53
|
-
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
-
|
58
|
+
!binary "RGF0ZQ==":
|
59
|
+
- !binary |-
|
60
|
+
RnJpLCAxMyBTZXAgMjAxMyAyMDozNjowMyBHTVQ=
|
61
|
+
!binary "U2VydmVy":
|
62
|
+
- !binary |-
|
63
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
64
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
65
|
+
- !binary |-
|
66
|
+
Mjcy
|
67
|
+
!binary "Q29udGVudC1UeXBl":
|
68
|
+
- !binary |-
|
69
|
+
YXBwbGljYXRpb24vanNvbg==
|
60
70
|
body:
|
61
|
-
encoding:
|
62
|
-
string: '{"elements":[{"account":"
|
71
|
+
encoding: US-ASCII
|
72
|
+
string: ! '{"elements":[{"account":"john.doe","domain":"tesla.com","createdDate":1378759081000,"updatedDate":1379101808000,"group":null,"aliases":[{"name":"john.doe","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":1,"totalPages":1,"actualPage":1}'
|
63
73
|
http_version:
|
64
|
-
recorded_at:
|
74
|
+
recorded_at: Fri, 13 Sep 2013 20:36:03 GMT
|
65
75
|
- request:
|
66
76
|
method: get
|
67
|
-
uri: http://admin:password@
|
77
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/accounts?account=test1&limit=&offset=
|
68
78
|
body:
|
69
|
-
encoding:
|
79
|
+
encoding: US-ASCII
|
70
80
|
string: ''
|
71
81
|
headers:
|
72
82
|
Accept:
|
@@ -78,19 +88,24 @@ http_interactions:
|
|
78
88
|
response:
|
79
89
|
status:
|
80
90
|
code: 200
|
81
|
-
message:
|
91
|
+
message: !binary |-
|
92
|
+
T0s=
|
82
93
|
headers:
|
83
|
-
|
84
|
-
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
-
|
94
|
+
!binary "RGF0ZQ==":
|
95
|
+
- !binary |-
|
96
|
+
RnJpLCAxMyBTZXAgMjAxMyAyMDozNjowNCBHTVQ=
|
97
|
+
!binary "U2VydmVy":
|
98
|
+
- !binary |-
|
99
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
100
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
101
|
+
- !binary |-
|
102
|
+
MjY4
|
103
|
+
!binary "Q29udGVudC1UeXBl":
|
104
|
+
- !binary |-
|
105
|
+
YXBwbGljYXRpb24vanNvbg==
|
91
106
|
body:
|
92
|
-
encoding:
|
93
|
-
string: '{"elements":[{"account":"
|
107
|
+
encoding: US-ASCII
|
108
|
+
string: ! '{"elements":[{"account":"test1","domain":"tesla.com","createdDate":1378759068000,"updatedDate":1379077065000,"group":"test","aliases":[{"name":"test1","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":1,"totalPages":1,"actualPage":1}'
|
94
109
|
http_version:
|
95
|
-
recorded_at:
|
110
|
+
recorded_at: Fri, 13 Sep 2013 20:36:03 GMT
|
96
111
|
recorded_with: VCR 2.5.0
|
@@ -2,7 +2,7 @@
|
|
2
2
|
http_interactions:
|
3
3
|
- request:
|
4
4
|
method: get
|
5
|
-
uri: http://admin:password@
|
5
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/accounts?limit=&offset=
|
6
6
|
body:
|
7
7
|
encoding: US-ASCII
|
8
8
|
string: ''
|
@@ -19,21 +19,21 @@ http_interactions:
|
|
19
19
|
message: !binary |-
|
20
20
|
T0s=
|
21
21
|
headers:
|
22
|
+
!binary "RGF0ZQ==":
|
23
|
+
- !binary |-
|
24
|
+
RnJpLCAxMyBTZXAgMjAxMyAyMDozNDoyNyBHTVQ=
|
22
25
|
!binary "U2VydmVy":
|
23
26
|
- !binary |-
|
24
|
-
|
27
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
28
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
29
|
+
- !binary |-
|
30
|
+
MTEwNA==
|
25
31
|
!binary "Q29udGVudC1UeXBl":
|
26
32
|
- !binary |-
|
27
33
|
YXBwbGljYXRpb24vanNvbg==
|
28
|
-
!binary "VHJhbnNmZXItRW5jb2Rpbmc=":
|
29
|
-
- !binary |-
|
30
|
-
Y2h1bmtlZA==
|
31
|
-
!binary "RGF0ZQ==":
|
32
|
-
- !binary |-
|
33
|
-
RnJpLCAwOSBBdWcgMjAxMyAwNjozNDowNCBHTVQ=
|
34
34
|
body:
|
35
35
|
encoding: US-ASCII
|
36
|
-
string: ! '{"elements":[],"totalElements":
|
36
|
+
string: ! '{"elements":[{"account":"agent.smith","domain":"tesla.com","createdDate":1378759089000,"updatedDate":1379098398000,"group":null,"aliases":[{"name":"agent.smith","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"john.doe","domain":"tesla.com","createdDate":1378759081000,"updatedDate":1379101808000,"group":null,"aliases":[{"name":"john.doe","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"test","domain":"tesla.com","createdDate":1379013802000,"updatedDate":1379077065000,"group":"test","aliases":[{"name":"test","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"test1","domain":"tesla.com","createdDate":1378759068000,"updatedDate":1379077065000,"group":"test","aliases":[{"name":"test1","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"test2","domain":"tesla.com","createdDate":1378759074000,"updatedDate":1379077065000,"group":"test","aliases":[{"name":"test2","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":5,"totalPages":1,"actualPage":1}'
|
37
37
|
http_version:
|
38
|
-
recorded_at:
|
38
|
+
recorded_at: Fri, 13 Sep 2013 20:34:27 GMT
|
39
39
|
recorded_with: VCR 2.5.0
|
@@ -2,7 +2,7 @@
|
|
2
2
|
http_interactions:
|
3
3
|
- request:
|
4
4
|
method: get
|
5
|
-
uri: http://admin:password@
|
5
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com/accounts?limit=4&offset=1
|
6
6
|
body:
|
7
7
|
encoding: US-ASCII
|
8
8
|
string: ''
|
@@ -19,21 +19,21 @@ http_interactions:
|
|
19
19
|
message: !binary |-
|
20
20
|
T0s=
|
21
21
|
headers:
|
22
|
+
!binary "RGF0ZQ==":
|
23
|
+
- !binary |-
|
24
|
+
VGh1LCAxMiBTZXAgMjAxMyAyMToyMTowNyBHTVQ=
|
22
25
|
!binary "U2VydmVy":
|
23
26
|
- !binary |-
|
24
|
-
|
27
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
28
|
+
!binary "Q29udGVudC1MZW5ndGg=":
|
29
|
+
- !binary |-
|
30
|
+
ODk0
|
25
31
|
!binary "Q29udGVudC1UeXBl":
|
26
32
|
- !binary |-
|
27
33
|
YXBwbGljYXRpb24vanNvbg==
|
28
|
-
!binary "VHJhbnNmZXItRW5jb2Rpbmc=":
|
29
|
-
- !binary |-
|
30
|
-
Y2h1bmtlZA==
|
31
|
-
!binary "RGF0ZQ==":
|
32
|
-
- !binary |-
|
33
|
-
U2F0LCAxMCBBdWcgMjAxMyAwMzozNToxNSBHTVQ=
|
34
34
|
body:
|
35
35
|
encoding: US-ASCII
|
36
|
-
string: ! '{"elements":[{"account":"
|
36
|
+
string: ! '{"elements":[{"account":"agent.smith","domain":"tesla.com","createdDate":1378759089000,"updatedDate":1378759089000,"group":null,"aliases":[{"name":"agent.smith","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"john.doe","domain":"tesla.com","createdDate":1378759081000,"updatedDate":1378759081000,"group":null,"aliases":[{"name":"john.doe","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"test","domain":"tesla.com","createdDate":1379013802000,"updatedDate":1379013802000,"group":null,"aliases":[{"name":"test","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"test1","domain":"tesla.com","createdDate":1378759068000,"updatedDate":1378759068000,"group":null,"aliases":[{"name":"test1","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":5,"totalPages":2,"actualPage":1}'
|
37
37
|
http_version:
|
38
|
-
recorded_at: Thu,
|
38
|
+
recorded_at: Thu, 12 Sep 2013 21:21:07 GMT
|
39
39
|
recorded_with: VCR 2.5.0
|
@@ -0,0 +1,75 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com//groups/accounts/available?account=
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json
|
12
|
+
Content-Type:
|
13
|
+
- application/json
|
14
|
+
Authorization:
|
15
|
+
- Basic YWRtaW46cGFzc3dvcmQ=
|
16
|
+
response:
|
17
|
+
status:
|
18
|
+
code: 200
|
19
|
+
message: !binary |-
|
20
|
+
T0s=
|
21
|
+
headers:
|
22
|
+
!binary "RGF0ZQ==":
|
23
|
+
- !binary |-
|
24
|
+
V2VkLCAxOCBTZXAgMjAxMyAyMjowNjoyNyBHTVQ=
|
25
|
+
!binary "U2VydmVy":
|
26
|
+
- !binary |-
|
27
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
28
|
+
!binary "VHJhbnNmZXItRW5jb2Rpbmc=":
|
29
|
+
- !binary |-
|
30
|
+
Y2h1bmtlZA==
|
31
|
+
!binary "Q29udGVudC1UeXBl":
|
32
|
+
- !binary |-
|
33
|
+
YXBwbGljYXRpb24vanNvbg==
|
34
|
+
body:
|
35
|
+
encoding: US-ASCII
|
36
|
+
string: ! '{"elements":[{"account":"agent.smith","domain":"tesla.com","createdDate":1378759089000,"updatedDate":1379098398000,"group":null,"aliases":[{"name":"agent.smith","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"},{"account":"john.doe","domain":"tesla.com","createdDate":1378759081000,"updatedDate":1379101808000,"group":null,"aliases":[{"name":"john.doe","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":2,"totalPages":1,"actualPage":1}'
|
37
|
+
http_version:
|
38
|
+
recorded_at: Wed, 18 Sep 2013 22:06:27 GMT
|
39
|
+
- request:
|
40
|
+
method: get
|
41
|
+
uri: http://admin:password@test.mxhero.com/webapi/api/v1/domains/tesla.com//groups/accounts/available?account=age
|
42
|
+
body:
|
43
|
+
encoding: US-ASCII
|
44
|
+
string: ''
|
45
|
+
headers:
|
46
|
+
Accept:
|
47
|
+
- application/json
|
48
|
+
Content-Type:
|
49
|
+
- application/json
|
50
|
+
Authorization:
|
51
|
+
- Basic YWRtaW46cGFzc3dvcmQ=
|
52
|
+
response:
|
53
|
+
status:
|
54
|
+
code: 200
|
55
|
+
message: !binary |-
|
56
|
+
T0s=
|
57
|
+
headers:
|
58
|
+
!binary "RGF0ZQ==":
|
59
|
+
- !binary |-
|
60
|
+
V2VkLCAxOCBTZXAgMjAxMyAyMjowNjoyOCBHTVQ=
|
61
|
+
!binary "U2VydmVy":
|
62
|
+
- !binary |-
|
63
|
+
QXBhY2hlLzIuMi4xNCAoVWJ1bnR1KQ==
|
64
|
+
!binary "VHJhbnNmZXItRW5jb2Rpbmc=":
|
65
|
+
- !binary |-
|
66
|
+
Y2h1bmtlZA==
|
67
|
+
!binary "Q29udGVudC1UeXBl":
|
68
|
+
- !binary |-
|
69
|
+
YXBwbGljYXRpb24vanNvbg==
|
70
|
+
body:
|
71
|
+
encoding: US-ASCII
|
72
|
+
string: ! '{"elements":[{"account":"agent.smith","domain":"tesla.com","createdDate":1378759089000,"updatedDate":1379098398000,"group":null,"aliases":[{"name":"agent.smith","domain":"tesla.com","dataSource":"manual"}],"dataSource":"manual"}],"totalElements":1,"totalPages":1,"actualPage":1}'
|
73
|
+
http_version:
|
74
|
+
recorded_at: Wed, 18 Sep 2013 22:06:28 GMT
|
75
|
+
recorded_with: VCR 2.5.0
|