elastic-site-search 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (101) hide show
  1. checksums.yaml +7 -0
  2. data/.circleci/config.yml +58 -0
  3. data/.gitignore +10 -0
  4. data/.travis.yml +13 -0
  5. data/Gemfile +4 -0
  6. data/LICENSE.txt +201 -0
  7. data/NOTICE.txt +3 -0
  8. data/README.md +418 -0
  9. data/Rakefile +1 -0
  10. data/elastic-site-search.gemspec +26 -0
  11. data/lib/data/ca-bundle.crt +3554 -0
  12. data/lib/elastic/site-search.rb +9 -0
  13. data/lib/elastic/site-search/client.rb +527 -0
  14. data/lib/elastic/site-search/configuration.rb +67 -0
  15. data/lib/elastic/site-search/exceptions.rb +11 -0
  16. data/lib/elastic/site-search/ext/backport-uri.rb +33 -0
  17. data/lib/elastic/site-search/request.rb +156 -0
  18. data/lib/elastic/site-search/result_set.rb +84 -0
  19. data/lib/elastic/site-search/sso.rb +22 -0
  20. data/lib/elastic/site-search/version.rb +5 -0
  21. data/logo-site-search.png +0 -0
  22. data/spec/client_spec.rb +728 -0
  23. data/spec/configuration_spec.rb +37 -0
  24. data/spec/fixtures/vcr/analytics_autoselects.yml +57 -0
  25. data/spec/fixtures/vcr/analytics_autoselects_with_document_type.yml +57 -0
  26. data/spec/fixtures/vcr/analytics_autoselects_with_document_type_and_time_range.yml +57 -0
  27. data/spec/fixtures/vcr/analytics_autoselects_with_time_range.yml +57 -0
  28. data/spec/fixtures/vcr/analytics_clicks.yml +57 -0
  29. data/spec/fixtures/vcr/analytics_clicks_with_document_type.yml +57 -0
  30. data/spec/fixtures/vcr/analytics_clicks_with_document_type_and_time_range.yml +57 -0
  31. data/spec/fixtures/vcr/analytics_clicks_with_time_range.yml +57 -0
  32. data/spec/fixtures/vcr/analytics_searches.yml +57 -0
  33. data/spec/fixtures/vcr/analytics_searches_with_document_type_and_time_range.yml +57 -0
  34. data/spec/fixtures/vcr/analytics_searches_with_time_range.yml +57 -0
  35. data/spec/fixtures/vcr/analytics_searchs_with_document_type.yml +57 -0
  36. data/spec/fixtures/vcr/analytics_top_no_result_queries.yml +57 -0
  37. data/spec/fixtures/vcr/analytics_top_no_result_queries_paginated.yml +57 -0
  38. data/spec/fixtures/vcr/analytics_top_queries.yml +57 -0
  39. data/spec/fixtures/vcr/analytics_top_queries_paginated.yml +57 -0
  40. data/spec/fixtures/vcr/analytics_top_queries_too_large.yml +53 -0
  41. data/spec/fixtures/vcr/async_create_or_update_document_failure.yml +48 -0
  42. data/spec/fixtures/vcr/async_create_or_update_document_success.yml +52 -0
  43. data/spec/fixtures/vcr/bulk_create_documents.yml +52 -0
  44. data/spec/fixtures/vcr/bulk_create_or_update_documents_failure.yml +47 -0
  45. data/spec/fixtures/vcr/bulk_create_or_update_documents_success.yml +52 -0
  46. data/spec/fixtures/vcr/bulk_create_or_update_documents_verbose_failure.yml +47 -0
  47. data/spec/fixtures/vcr/bulk_create_or_update_documents_verbose_success.yml +52 -0
  48. data/spec/fixtures/vcr/bulk_destroy_documents.yml +47 -0
  49. data/spec/fixtures/vcr/crawl_url.yml +47 -0
  50. data/spec/fixtures/vcr/create_document.yml +52 -0
  51. data/spec/fixtures/vcr/create_document_type.yml +47 -0
  52. data/spec/fixtures/vcr/create_domain.yml +47 -0
  53. data/spec/fixtures/vcr/create_engine.yml +47 -0
  54. data/spec/fixtures/vcr/create_or_update_document_create.yml +51 -0
  55. data/spec/fixtures/vcr/create_or_update_document_update.yml +51 -0
  56. data/spec/fixtures/vcr/create_user.yml +47 -0
  57. data/spec/fixtures/vcr/destroy_document.yml +43 -0
  58. data/spec/fixtures/vcr/destroy_document_type.yml +43 -0
  59. data/spec/fixtures/vcr/destroy_domain.yml +43 -0
  60. data/spec/fixtures/vcr/destroy_engine.yml +43 -0
  61. data/spec/fixtures/vcr/destroy_non_existent_document_type.yml +45 -0
  62. data/spec/fixtures/vcr/document_receipts_multiple.yml +48 -0
  63. data/spec/fixtures/vcr/document_receipts_multiple_complete.yml +48 -0
  64. data/spec/fixtures/vcr/document_type_search.yml +63 -0
  65. data/spec/fixtures/vcr/document_type_search_pagination.yml +47 -0
  66. data/spec/fixtures/vcr/document_type_suggest.yml +52 -0
  67. data/spec/fixtures/vcr/document_type_suggest_pagination.yml +47 -0
  68. data/spec/fixtures/vcr/engine_search.yml +67 -0
  69. data/spec/fixtures/vcr/engine_search_facets.yml +164 -0
  70. data/spec/fixtures/vcr/engine_search_pagination.yml +47 -0
  71. data/spec/fixtures/vcr/engine_suggest.yml +55 -0
  72. data/spec/fixtures/vcr/engine_suggest_pagination.yml +47 -0
  73. data/spec/fixtures/vcr/find_document.yml +50 -0
  74. data/spec/fixtures/vcr/find_document_type.yml +47 -0
  75. data/spec/fixtures/vcr/find_domain.yml +47 -0
  76. data/spec/fixtures/vcr/find_domain_failure.yml +45 -0
  77. data/spec/fixtures/vcr/find_engine.yml +47 -0
  78. data/spec/fixtures/vcr/list_document_type.yml +47 -0
  79. data/spec/fixtures/vcr/list_documents.yml +71 -0
  80. data/spec/fixtures/vcr/list_documents_with_pagination.yml +71 -0
  81. data/spec/fixtures/vcr/list_domains.yml +47 -0
  82. data/spec/fixtures/vcr/list_engines.yml +48 -0
  83. data/spec/fixtures/vcr/list_users.yml +47 -0
  84. data/spec/fixtures/vcr/list_users_with_pagination.yml +47 -0
  85. data/spec/fixtures/vcr/log_clickthrough_failure.yml +45 -0
  86. data/spec/fixtures/vcr/log_clickthrough_success.yml +47 -0
  87. data/spec/fixtures/vcr/recrawl_domain_failure.yml +46 -0
  88. data/spec/fixtures/vcr/recrawl_domain_success.yml +47 -0
  89. data/spec/fixtures/vcr/show_user.yml +47 -0
  90. data/spec/fixtures/vcr/update_document.yml +50 -0
  91. data/spec/fixtures/vcr/update_document_unknown_field_failure.yml +48 -0
  92. data/spec/fixtures/vcr/update_documents_failure_non_existent_document.yml +47 -0
  93. data/spec/fixtures/vcr/update_documents_success.yml +47 -0
  94. data/spec/fixtures/vcr/users_client_secret_incorrect.yml +44 -0
  95. data/spec/fixtures/vcr/users_no_api_key.yml +44 -0
  96. data/spec/fixtures/vcr/users_no_client_id_or_secret.yml +45 -0
  97. data/spec/platform_spec.rb +95 -0
  98. data/spec/spec_helper.rb +27 -0
  99. data/spec/ssl_spec.rb +34 -0
  100. data/spec/sso_spec.rb +24 -0
  101. metadata +279 -0
@@ -0,0 +1,47 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: put
5
+ uri: http://hello:@localhost:3000/api/v1/engines/crawler-demo-site/domains/51534c6e2ed960cc79000001/crawl_url.json
6
+ body:
7
+ encoding: UTF-8
8
+ string: ! '{"url":"http://crawler-demo-site.herokuapp.com/2012/01/01/first-post.html"}'
9
+ headers:
10
+ Accept:
11
+ - ! '*/*'
12
+ X-Swiftype-Client:
13
+ - elastic-app-search-ruby
14
+ X-Swiftype-Client-Version:
15
+ - 1.0.0
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Content-Type:
24
+ - application/json; charset=utf-8
25
+ X-Ua-Compatible:
26
+ - IE=Edge
27
+ Etag:
28
+ - ! '"dc3e7df6ad36f807472e018fd1e7baeb"'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
31
+ Set-Cookie:
32
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJWYzYTM5YTQzZTIwYmZmZWQ3MzIxZGFlMmFhN2RhNDNhBjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--e96bdca607c9e4b372e020b9aa2f9a770769c1ec;
33
+ path=/; HttpOnly
34
+ X-Request-Id:
35
+ - 2e31f41f48df91f9de70039d65cca481
36
+ X-Runtime:
37
+ - '0.079952'
38
+ Connection:
39
+ - close
40
+ Server:
41
+ - thin 1.5.0 codename Knife
42
+ body:
43
+ encoding: US-ASCII
44
+ string: ! '{"external_id":"9508ace2e1ba669854eb49fbe9429952ff1a6d4c","url":"http://crawler-demo-site.herokuapp.com/2012/01/01/first-post.html"}'
45
+ http_version:
46
+ recorded_at: Thu, 12 Sep 2013 23:15:31 GMT
47
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,52 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://hello:@localhost:3000/api/v1/engines/site-search-api-example/document_types/videos/documents.json
6
+ body:
7
+ encoding: UTF-8
8
+ string:
9
+ ! '{"document":{"external_id":"INscMGmhmX4","fields":[{"name":"url","value":"http://www.youtube.com/watch?v=v1uyQZNg2vE","type":"enum"},{"name":"thumbnail_url","value":"https://i.ytimg.com/vi/INscMGmhmX4/mqdefault.jpg","type":"enum"},{"name":"channel_id","value":"UCTzVrd9ExsI3Zgnlh3_btLg","type":"enum"},{"name":"title","value":"The
10
+ Original Grumpy Cat","type":"string"},{"name":"category_name","value":"Pets
11
+ & Animals","type":"string"}]}}'
12
+ headers:
13
+ Accept:
14
+ - ! "*/*"
15
+ X-Swiftype-Client:
16
+ - elastic-app-search-ruby
17
+ X-Swiftype-Client-Version:
18
+ - 1.0.0
19
+ Content-Type:
20
+ - application/json
21
+ response:
22
+ status:
23
+ code: 200
24
+ message: OK
25
+ headers:
26
+ Content-Type:
27
+ - application/json; charset=utf-8
28
+ X-Ua-Compatible:
29
+ - IE=Edge
30
+ Etag:
31
+ - ! '"5247c7b2d32d42ddedbe443f986a4de6"'
32
+ Cache-Control:
33
+ - max-age=0, private, must-revalidate
34
+ Set-Cookie:
35
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJTg4NzczNDMyMGZlMGMwZjIwZTMwMjA1YmMwNjc4NjJhBjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--3b7af0396c432043e915447bfd2cbf3fa506d77f;
36
+ path=/; HttpOnly
37
+ X-Request-Id:
38
+ - 17c210b74766b815e46049e9456749d0
39
+ X-Runtime:
40
+ - "0.217177"
41
+ Connection:
42
+ - close
43
+ Server:
44
+ - thin 1.5.0 codename Knife
45
+ body:
46
+ encoding: US-ASCII
47
+ string:
48
+ ! '{"external_id":"INscMGmhmX4","engine_id":"51b92f982ed960a844000248","document_type_id":"523231e62ed9605898000020","id":"52323cbf2ed9605898000035","_id":"52323cbf2ed9605898000035","updated_at":"2013-09-12T22:14:23Z","url":"http://www.youtube.com/watch?v=v1uyQZNg2vE","thumbnail_url":"https://i.ytimg.com/vi/INscMGmhmX4/mqdefault.jpg","channel_id":"UCTzVrd9ExsI3Zgnlh3_btLg","title":"The
49
+ Original Grumpy Cat","category_name":"Pets & Animals"}'
50
+ http_version:
51
+ recorded_at: Thu, 12 Sep 2013 22:14:23 GMT
52
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,47 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://hello:@localhost:3000/api/v1/engines/site-search-api-example/document_types.json
6
+ body:
7
+ encoding: UTF-8
8
+ string: ! '{"document_type":{"name":"new_doc_type"}}'
9
+ headers:
10
+ Accept:
11
+ - ! "*/*"
12
+ X-Swiftype-Client:
13
+ - elastic-app-search-ruby
14
+ X-Swiftype-Client-Version:
15
+ - 1.0.0
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Content-Type:
24
+ - application/json; charset=utf-8
25
+ X-Ua-Compatible:
26
+ - IE=Edge
27
+ Etag:
28
+ - ! '"06f1be79a40ef40229e7fe40dfd2c3a5"'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
31
+ Set-Cookie:
32
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJWUwYzc2ZmY5ZWJkZWY4MzVmMGU1ZDdhNTUzMmZkNjk3BjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--a4f56ce685daf5b6bd20bc129a83967ab6ae35e9;
33
+ path=/; HttpOnly
34
+ X-Request-Id:
35
+ - feee119776285704decf36d041dbe2cb
36
+ X-Runtime:
37
+ - "0.190533"
38
+ Connection:
39
+ - close
40
+ Server:
41
+ - thin 1.5.0 codename Knife
42
+ body:
43
+ encoding: US-ASCII
44
+ string: ! '{"id":"523248752ed9605898000048","name":"new_doc_type","slug":"new-doc-type","engine_id":"51b92f982ed960a844000248","updated_at":"2013-09-12T23:04:21Z","document_count":0,"field_mapping":{}}'
45
+ http_version:
46
+ recorded_at: Thu, 12 Sep 2013 23:04:21 GMT
47
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,47 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://hello:@localhost:3000/api/v1/engines/crawler-demo-site/domains.json
6
+ body:
7
+ encoding: UTF-8
8
+ string: ! '{"domain":{"submitted_url":"http://www.zombo.com/"}}'
9
+ headers:
10
+ Accept:
11
+ - ! '*/*'
12
+ X-Swiftype-Client:
13
+ - elastic-app-search-ruby
14
+ X-Swiftype-Client-Version:
15
+ - 1.0.0
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Content-Type:
24
+ - application/json; charset=utf-8
25
+ X-Ua-Compatible:
26
+ - IE=Edge
27
+ Etag:
28
+ - ! '"83dd9f2e5a7609c46eb3aa26404c5e12"'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
31
+ Set-Cookie:
32
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJTZiNjQ2NDljNTViM2VmOTAzZDgyMTQ4ZGRlODVmYjA4BjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--365fbf71cc3dafd17b3179911132d52620b54338;
33
+ path=/; HttpOnly
34
+ X-Request-Id:
35
+ - a17f5806b66d854ee7def9d484de5efb
36
+ X-Runtime:
37
+ - '1.536812'
38
+ Connection:
39
+ - close
40
+ Server:
41
+ - thin 1.5.0 codename Knife
42
+ body:
43
+ encoding: US-ASCII
44
+ string: ! '{"id":"52324b132ed960589800004a","engine_id":"51534c502ed960a1e6000005","submitted_url":"http://www.zombo.com/","start_crawl_url":"http://www.zombo.com/","crawling":false,"document_count":0,"updated_at":"2013-09-12T23:15:32Z"}'
45
+ http_version:
46
+ recorded_at: Thu, 12 Sep 2013 23:15:33 GMT
47
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,47 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://hello:@localhost:3000/api/v1/engines.json
6
+ body:
7
+ encoding: UTF-8
8
+ string: ! '{"engine":{"name":"new engine from spec"}}'
9
+ headers:
10
+ Accept:
11
+ - ! '*/*'
12
+ X-Swiftype-Client:
13
+ - elastic-app-search-ruby
14
+ X-Swiftype-Client-Version:
15
+ - 1.0.0
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Content-Type:
24
+ - application/json; charset=utf-8
25
+ X-Ua-Compatible:
26
+ - IE=Edge
27
+ Etag:
28
+ - ! '"f022b16e11b2d1d15380ed8f23f78c8c"'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
31
+ Set-Cookie:
32
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJTA3ZThlODdjZjI1ZmI1MzU4ODY3YjQzMTFjN2FhMGI4BjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--c43d6fb40ab9e64c5c31d1f16e708a305817fc57;
33
+ path=/; HttpOnly
34
+ X-Request-Id:
35
+ - 57c41803f457a67906a4e3f2e844140e
36
+ X-Runtime:
37
+ - '0.068736'
38
+ Connection:
39
+ - close
40
+ Server:
41
+ - thin 1.5.0 codename Knife
42
+ body:
43
+ encoding: US-ASCII
44
+ string: ! '{"name":"new engine from spec","slug":"new-engine-from-spec","key":"wpJr9UJKygVyzEVN7GvM","id":"5232326c2ed9605898000033","_id":"5232326c2ed9605898000033","updated_at":"2013-09-12T21:30:20Z","document_count":0}'
45
+ http_version:
46
+ recorded_at: Thu, 12 Sep 2013 21:30:20 GMT
47
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,51 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://hello:@localhost:3000/api/v1/engines/site-search-api-example/document_types/videos/documents/create_or_update.json
6
+ body:
7
+ encoding: UTF-8
8
+ string:
9
+ ! '{"document":{"external_id":"foobar","fields":[{"type":"string","name":"title","value":"new
10
+ document"}]}}'
11
+ headers:
12
+ Accept:
13
+ - ! "*/*"
14
+ X-Swiftype-Client:
15
+ - elastic-app-search-ruby
16
+ X-Swiftype-Client-Version:
17
+ - 1.0.0
18
+ Content-Type:
19
+ - application/json
20
+ response:
21
+ status:
22
+ code: 200
23
+ message: OK
24
+ headers:
25
+ Content-Type:
26
+ - application/json; charset=utf-8
27
+ X-Ua-Compatible:
28
+ - IE=Edge
29
+ Etag:
30
+ - ! '"3763bb197507514eb8ac090998b3deb3"'
31
+ Cache-Control:
32
+ - max-age=0, private, must-revalidate
33
+ Set-Cookie:
34
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJWFiYTAxYjJhYzJhOTdlNDY0M2QzMjg4ZjNhMmIzNTNhBjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--0a519708383944dfc4d388112b215f9cd2e62319;
35
+ path=/; HttpOnly
36
+ X-Request-Id:
37
+ - ba5e1e5a3e53e6fc25a07f64d86e16b5
38
+ X-Runtime:
39
+ - "0.065348"
40
+ Connection:
41
+ - close
42
+ Server:
43
+ - thin 1.5.0 codename Knife
44
+ body:
45
+ encoding: US-ASCII
46
+ string:
47
+ ! '{"external_id":"foobar","engine_id":"51b92f982ed960a844000248","document_type_id":"523231e62ed9605898000020","id":"52323fe92ed960589800003a","_id":"52323fe92ed960589800003a","updated_at":"2013-09-12T22:27:53Z","title":"new
48
+ document"}'
49
+ http_version:
50
+ recorded_at: Thu, 12 Sep 2013 22:27:53 GMT
51
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,51 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://hello:@localhost:3000/api/v1/engines/site-search-api-example/document_types/videos/documents/create_or_update.json
6
+ body:
7
+ encoding: UTF-8
8
+ string:
9
+ ! '{"document":{"external_id":"FtX8nswnUKU","fields":[{"type":"string","name":"title","value":"new
10
+ title"}]}}'
11
+ headers:
12
+ Accept:
13
+ - ! "*/*"
14
+ X-Swiftype-Client:
15
+ - elastic-app-search-ruby
16
+ X-Swiftype-Client-Version:
17
+ - 1.0.0
18
+ Content-Type:
19
+ - application/json
20
+ response:
21
+ status:
22
+ code: 200
23
+ message: OK
24
+ headers:
25
+ Content-Type:
26
+ - application/json; charset=utf-8
27
+ X-Ua-Compatible:
28
+ - IE=Edge
29
+ Etag:
30
+ - ! '"488aba5c2ad2a659d05843295a3498fc"'
31
+ Cache-Control:
32
+ - max-age=0, private, must-revalidate
33
+ Set-Cookie:
34
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJTE4YzllZGM2YmZiNTZkYzYyZmQ0NjE3ZGNiOGJkNWNhBjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--64335e3c3b784178b315963cd727aa9aef214cc4;
35
+ path=/; HttpOnly
36
+ X-Request-Id:
37
+ - 8d4b593a1091399681f7a24e63497363
38
+ X-Runtime:
39
+ - "0.041548"
40
+ Connection:
41
+ - close
42
+ Server:
43
+ - thin 1.5.0 codename Knife
44
+ body:
45
+ encoding: US-ASCII
46
+ string:
47
+ ! '{"external_id":"FtX8nswnUKU","engine_id":"51b92f982ed960a844000248","document_type_id":"523231e62ed9605898000020","id":"523231eb2ed9605898000027","_id":"523231eb2ed9605898000027","updated_at":"2013-09-12T22:42:28Z","title":"new
48
+ title"}'
49
+ http_version:
50
+ recorded_at: Thu, 12 Sep 2013 22:42:28 GMT
51
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,47 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://hello:@localhost:3000/api/v1/users.json
6
+ body:
7
+ encoding: UTF-8
8
+ string: ! '{"client_id":"0d94f7cf2bd1e65a7e1f9f929d1bcb2b248af69b8112d24484e87014125538f8","client_secret":"f600fb0b16b516cbb9b9f0eeb60f3b35f685b5ec4a94694ae57b5bbb8860f240"}'
9
+ headers:
10
+ Accept:
11
+ - ! '*/*'
12
+ X-Swiftype-Client:
13
+ - elastic-app-search-ruby
14
+ X-Swiftype-Client-Version:
15
+ - 1.0.0
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Content-Type:
24
+ - application/json; charset=utf-8
25
+ X-Ua-Compatible:
26
+ - IE=Edge
27
+ Etag:
28
+ - ! '"f667288357fd5b6401e78f25c6bc7216"'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
31
+ Set-Cookie:
32
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJTVlZDQ4ZjdmNjZmNjRjMGI2NjllMzI5ZDdmN2JlZTY1BjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--65fe1f516fe61490759edfc961a4d6793df541fb;
33
+ path=/; HttpOnly
34
+ X-Request-Id:
35
+ - 1d5d3cb5f037bc9533615229314a6772
36
+ X-Runtime:
37
+ - '0.242698'
38
+ Connection:
39
+ - close
40
+ Server:
41
+ - thin 1.5.0 codename Knife
42
+ body:
43
+ encoding: US-ASCII
44
+ string: ! '{"id":"523262032ed960589800004b","access_token":"06feb198d229d781f53a9f2e9747569e3494d3a5a6a90687231847462063911c"}'
45
+ http_version:
46
+ recorded_at: Fri, 13 Sep 2013 00:53:23 GMT
47
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,43 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: delete
5
+ uri: http://hello:@localhost:3000/api/v1/engines/site-search-api-example/document_types/videos/documents/INscMGmhmX4.json
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ""
9
+ headers:
10
+ Accept:
11
+ - ! "*/*"
12
+ X-Swiftype-Client:
13
+ - elastic-app-search-ruby
14
+ X-Swiftype-Client-Version:
15
+ - 1.0.0
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 204
21
+ message: No Content
22
+ headers:
23
+ X-Ua-Compatible:
24
+ - IE=Edge
25
+ Cache-Control:
26
+ - no-cache
27
+ Set-Cookie:
28
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJThiZGQ1MDkyNGQ0MjMyMDA2NWVjMmJjMDMxMmRjNzdmBjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--91735a6824ba6c6e0b26bb7ba687d4dcf057a16e;
29
+ path=/; HttpOnly
30
+ X-Request-Id:
31
+ - 5f57953bef26af9f39e7bc0309c77420
32
+ X-Runtime:
33
+ - "0.059379"
34
+ Connection:
35
+ - close
36
+ Server:
37
+ - thin 1.5.0 codename Knife
38
+ body:
39
+ encoding: US-ASCII
40
+ string: ""
41
+ http_version:
42
+ recorded_at: Thu, 12 Sep 2013 22:15:17 GMT
43
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,43 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: delete
5
+ uri: http://hello:@localhost:3000/api/v1/engines/site-search-api-example/document_types/new-doc-type.json
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ""
9
+ headers:
10
+ Accept:
11
+ - ! "*/*"
12
+ X-Swiftype-Client:
13
+ - elastic-app-search-ruby
14
+ X-Swiftype-Client-Version:
15
+ - 1.0.0
16
+ Content-Type:
17
+ - application/json
18
+ response:
19
+ status:
20
+ code: 204
21
+ message: No Content
22
+ headers:
23
+ X-Ua-Compatible:
24
+ - IE=Edge
25
+ Cache-Control:
26
+ - no-cache
27
+ Set-Cookie:
28
+ - _session_id=BAh7B0kiD3Nlc3Npb25faWQGOgZFRkkiJThiMTA5ODM1MzYzMGIzNWYyYzA0NTE0NTBhZjc0NjExBjsAVEkiGXdhcmRlbi51c2VyLnVzZXIua2V5BjsAVFsISSIJVXNlcgY7AEZbBlU6Gk1vcGVkOjpCU09OOjpPYmplY3RJZCIRUDg5%2By7ZYCnHAAABSSIiJDJhJDEwJE1rNmZOdHA1cC9ZNVIuQU5sZFB2UWUGOwBU--bfb00f5e3c15f13ff47e9f6540a212bd33e6d9c5;
29
+ path=/; HttpOnly
30
+ X-Request-Id:
31
+ - 9d450a01b3860197cf381d4451cd41e3
32
+ X-Runtime:
33
+ - "0.040484"
34
+ Connection:
35
+ - close
36
+ Server:
37
+ - thin 1.5.0 codename Knife
38
+ body:
39
+ encoding: US-ASCII
40
+ string: ""
41
+ http_version:
42
+ recorded_at: Thu, 12 Sep 2013 23:04:28 GMT
43
+ recorded_with: VCR 2.5.0