switchboard-contract 1.9.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (80) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +22 -0
  3. data/README.md +31 -0
  4. data/Rakefile +3 -0
  5. data/contracts/3/compiled/advice_session.avpr +190 -0
  6. data/contracts/3/compiled/advice_session_image.avpr +36 -0
  7. data/contracts/3/compiled/advice_session_review.avpr +90 -0
  8. data/contracts/3/compiled/advisor.avpr +77 -0
  9. data/contracts/3/compiled/advisor_config.avpr +38 -0
  10. data/contracts/3/compiled/lawyer.avpr +83 -0
  11. data/contracts/3/compiled/location.avpr +128 -0
  12. data/contracts/3/compiled/offer.avpr +111 -0
  13. data/contracts/3/compiled/package.avpr +85 -0
  14. data/contracts/3/compiled/package_detail.avpr +100 -0
  15. data/contracts/3/compiled/provider_offer.avpr +144 -0
  16. data/contracts/3/compiled/specialty.avpr +61 -0
  17. data/contracts/3/compiled/user.avpr +50 -0
  18. data/contracts/3/compiled/user_authentication.avpr +111 -0
  19. data/contracts/3/source/advice_session.avdl +72 -0
  20. data/contracts/3/source/advice_session_image.avdl +16 -0
  21. data/contracts/3/source/advice_session_review.avdl +40 -0
  22. data/contracts/3/source/advisor.avdl +30 -0
  23. data/contracts/3/source/advisor_config.avdl +17 -0
  24. data/contracts/3/source/common.inc +20 -0
  25. data/contracts/3/source/lawyer.avdl +45 -0
  26. data/contracts/3/source/location.avdl +76 -0
  27. data/contracts/3/source/offer.avdl +51 -0
  28. data/contracts/3/source/package.avdl +36 -0
  29. data/contracts/3/source/package_detail.avdl +41 -0
  30. data/contracts/3/source/provider_offer.avdl +38 -0
  31. data/contracts/3/source/specialty.avdl +33 -0
  32. data/contracts/3/source/user.avdl +12 -0
  33. data/contracts/3/source/user_authentication.avdl +57 -0
  34. data/contracts/4/compiled/lawyer.avpr +127 -0
  35. data/contracts/4/compiled/lawyer_address.avpr +54 -0
  36. data/contracts/4/compiled/review.avpr +44 -0
  37. data/contracts/4/compiled/specialty.avpr +43 -0
  38. data/contracts/4/source/lawyer.avdl +69 -0
  39. data/contracts/4/source/lawyer_address.avdl +31 -0
  40. data/contracts/4/source/review.avdl +28 -0
  41. data/contracts/4/source/specialty.avdl +23 -0
  42. data/contracts/messaging/compiled/access_token.avpr +41 -0
  43. data/contracts/messaging/compiled/channel.avpr +111 -0
  44. data/contracts/messaging/source/access_token.avdl +21 -0
  45. data/contracts/messaging/source/channel.avdl +59 -0
  46. data/contracts/mobile/compiled/advice_session.avpr +160 -0
  47. data/contracts/mobile/compiled/checkout.avpr +115 -0
  48. data/contracts/mobile/compiled/lawyer.avpr +787 -0
  49. data/contracts/mobile/compiled/offer.avpr +111 -0
  50. data/contracts/mobile/compiled/package.avpr +85 -0
  51. data/contracts/mobile/compiled/package_detail.avpr +100 -0
  52. data/contracts/mobile/compiled/package_slug.avpr +67 -0
  53. data/contracts/mobile/compiled/promotion.avpr +45 -0
  54. data/contracts/mobile/compiled/provider_offer.avpr +144 -0
  55. data/contracts/mobile/compiled/review.avpr +83 -0
  56. data/contracts/mobile/compiled/specialty.avpr +55 -0
  57. data/contracts/mobile/source/advice_session.avdl +61 -0
  58. data/contracts/mobile/source/checkout.avdl +90 -0
  59. data/contracts/mobile/source/lawyer.avdl +321 -0
  60. data/contracts/mobile/source/offer.avdl +51 -0
  61. data/contracts/mobile/source/package.avdl +36 -0
  62. data/contracts/mobile/source/package_detail.avdl +41 -0
  63. data/contracts/mobile/source/package_slug.avdl +30 -0
  64. data/contracts/mobile/source/promotion.avdl +18 -0
  65. data/contracts/mobile/source/provider_offer.avdl +38 -0
  66. data/contracts/mobile/source/review.avdl +43 -0
  67. data/contracts/mobile/source/specialty.avdl +32 -0
  68. data/contracts/sales_force/compiled/account.avpr +94 -0
  69. data/contracts/sales_force/compiled/account_professional.avpr +39 -0
  70. data/contracts/sales_force/source/account.avdl +50 -0
  71. data/contracts/sales_force/source/account_professional.avdl +14 -0
  72. data/contracts/verify/compiled/lawyer.avpr +79 -0
  73. data/contracts/verify/compiled/license.avpr +64 -0
  74. data/contracts/verify/source/lawyer.avdl +41 -0
  75. data/contracts/verify/source/license.avdl +36 -0
  76. data/lib/switchboard/contract.rb +8 -0
  77. data/lib/switchboard/contract/documentation.rb +7 -0
  78. data/lib/switchboard/contract/service.rb +15 -0
  79. data/lib/switchboard/contract/version.rb +5 -0
  80. metadata +164 -0
@@ -0,0 +1,115 @@
1
+ {
2
+ "protocol" : "Checkout",
3
+ "namespace" : "Switchboard",
4
+ "types" : [ {
5
+ "type" : "record",
6
+ "name" : "Checkout",
7
+ "doc" : "The main class for this protocol",
8
+ "fields" : [ {
9
+ "name" : "id",
10
+ "type" : "int"
11
+ }, {
12
+ "name" : "specialty_id",
13
+ "type" : "int"
14
+ }, {
15
+ "name" : "advisor_id",
16
+ "type" : "int"
17
+ }, {
18
+ "name" : "review_id",
19
+ "type" : "int"
20
+ }, {
21
+ "name" : "state",
22
+ "type" : "string"
23
+ }, {
24
+ "name" : "called",
25
+ "type" : "boolean"
26
+ }, {
27
+ "name" : "advice_session_image_token",
28
+ "type" : [ "null", "string" ],
29
+ "default" : null
30
+ }, {
31
+ "name" : "chose_advisor",
32
+ "type" : "boolean"
33
+ } ]
34
+ }, {
35
+ "type" : "record",
36
+ "name" : "ImageParams",
37
+ "doc" : "Params to create AdviceSessionImages when the file is already on S3",
38
+ "fields" : [ {
39
+ "name" : "token",
40
+ "type" : "string"
41
+ }, {
42
+ "name" : "filename",
43
+ "type" : "string"
44
+ } ]
45
+ }, {
46
+ "type" : "record",
47
+ "name" : "CheckoutCreateParams",
48
+ "doc" : "Params to create a new Checkout",
49
+ "fields" : [ {
50
+ "name" : "provider_id",
51
+ "type" : "int"
52
+ }, {
53
+ "name" : "offer_id",
54
+ "type" : "int"
55
+ }, {
56
+ "name" : "specialty_id",
57
+ "type" : "int"
58
+ }, {
59
+ "name" : "state_id",
60
+ "type" : "int"
61
+ }, {
62
+ "name" : "payment_gateway",
63
+ "type" : [ "null", "string" ],
64
+ "default" : null
65
+ }, {
66
+ "name" : "card_id",
67
+ "type" : "string"
68
+ }, {
69
+ "name" : "client_name",
70
+ "type" : "string"
71
+ }, {
72
+ "name" : "card_name",
73
+ "type" : "string"
74
+ }, {
75
+ "name" : "email_address",
76
+ "type" : "string"
77
+ }, {
78
+ "name" : "phone_number",
79
+ "type" : "string"
80
+ }, {
81
+ "name" : "uploaded_image_token",
82
+ "type" : [ "null", "string" ],
83
+ "default" : null
84
+ }, {
85
+ "name" : "promo_code",
86
+ "type" : [ "null", "string" ],
87
+ "default" : null
88
+ }, {
89
+ "name" : "source",
90
+ "type" : "string"
91
+ }, {
92
+ "name" : "remote_ip",
93
+ "type" : "string"
94
+ }, {
95
+ "name" : "uploaded_images",
96
+ "type" : {
97
+ "type" : "array",
98
+ "items" : "ImageParams"
99
+ }
100
+ } ]
101
+ } ],
102
+ "messages" : {
103
+ "create" : {
104
+ "doc" : "Create a new Checkout",
105
+ "request" : [ {
106
+ "name" : "checkout",
107
+ "type" : "CheckoutCreateParams"
108
+ } ],
109
+ "response" : {
110
+ "type" : "array",
111
+ "items" : "Checkout"
112
+ }
113
+ }
114
+ }
115
+ }
@@ -0,0 +1,787 @@
1
+ {
2
+ "protocol" : "Lawyer",
3
+ "namespace" : "Switchboard",
4
+ "types" : [ {
5
+ "type" : "record",
6
+ "name" : "Phone",
7
+ "fields" : [ {
8
+ "name" : "area_code",
9
+ "type" : "string"
10
+ }, {
11
+ "name" : "local_number",
12
+ "type" : "string"
13
+ }, {
14
+ "name" : "type",
15
+ "type" : "string"
16
+ } ]
17
+ }, {
18
+ "type" : "record",
19
+ "name" : "Address",
20
+ "fields" : [ {
21
+ "name" : "id",
22
+ "type" : "int"
23
+ }, {
24
+ "name" : "lawyer_id",
25
+ "type" : "int"
26
+ }, {
27
+ "name" : "address_line1",
28
+ "type" : "string"
29
+ }, {
30
+ "name" : "address_line2",
31
+ "type" : "string"
32
+ }, {
33
+ "name" : "city",
34
+ "type" : "string"
35
+ }, {
36
+ "name" : "state",
37
+ "type" : "string"
38
+ }, {
39
+ "name" : "postal_code",
40
+ "type" : "string"
41
+ }, {
42
+ "name" : "standardized_address",
43
+ "type" : "string"
44
+ }, {
45
+ "name" : "location_id",
46
+ "type" : "int"
47
+ }, {
48
+ "name" : "latitude",
49
+ "type" : "float"
50
+ }, {
51
+ "name" : "longitude",
52
+ "type" : "float"
53
+ }, {
54
+ "name" : "phones",
55
+ "type" : {
56
+ "type" : "array",
57
+ "items" : "Phone"
58
+ }
59
+ }, {
60
+ "name" : "firm_name",
61
+ "type" : "string"
62
+ } ]
63
+ }, {
64
+ "type" : "record",
65
+ "name" : "License",
66
+ "fields" : [ {
67
+ "name" : "id",
68
+ "type" : "int"
69
+ }, {
70
+ "name" : "state",
71
+ "type" : "string"
72
+ }, {
73
+ "name" : "status",
74
+ "type" : "string"
75
+ }, {
76
+ "name" : "status_type",
77
+ "type" : "string"
78
+ }, {
79
+ "name" : "license_date",
80
+ "type" : "int"
81
+ }, {
82
+ "name" : "licensing_authority_id",
83
+ "type" : "int"
84
+ }, {
85
+ "name" : "last_updated",
86
+ "type" : "int"
87
+ } ]
88
+ }, {
89
+ "type" : "record",
90
+ "name" : "Sanction",
91
+ "fields" : [ {
92
+ "name" : "id",
93
+ "type" : "int"
94
+ }, {
95
+ "name" : "lawyer_id",
96
+ "type" : "int"
97
+ }, {
98
+ "name" : "license_id",
99
+ "type" : "int"
100
+ }, {
101
+ "name" : "state",
102
+ "type" : "string"
103
+ }, {
104
+ "name" : "name",
105
+ "type" : "string"
106
+ }, {
107
+ "name" : "type",
108
+ "type" : "string"
109
+ }, {
110
+ "name" : "sanction_date",
111
+ "type" : "int"
112
+ }, {
113
+ "name" : "updated_at",
114
+ "type" : "int"
115
+ }, {
116
+ "name" : "description",
117
+ "type" : "string"
118
+ }, {
119
+ "name" : "interpretation",
120
+ "type" : "string"
121
+ }, {
122
+ "name" : "comment",
123
+ "type" : "string"
124
+ } ]
125
+ }, {
126
+ "type" : "record",
127
+ "name" : "Fee",
128
+ "fields" : [ {
129
+ "name" : "name",
130
+ "type" : "string"
131
+ }, {
132
+ "name" : "symbolic_name",
133
+ "type" : "string"
134
+ }, {
135
+ "name" : "min_rate",
136
+ "type" : "int"
137
+ }, {
138
+ "name" : "max_rate",
139
+ "type" : "int"
140
+ } ]
141
+ }, {
142
+ "type" : "record",
143
+ "name" : "AdditionalProfileLink",
144
+ "fields" : [ {
145
+ "name" : "id",
146
+ "type" : "int"
147
+ }, {
148
+ "name" : "url",
149
+ "type" : "string"
150
+ }, {
151
+ "name" : "title",
152
+ "type" : "string"
153
+ }, {
154
+ "name" : "social_network",
155
+ "type" : "string"
156
+ }, {
157
+ "name" : "rss",
158
+ "type" : "string"
159
+ }, {
160
+ "name" : "rssable",
161
+ "type" : "boolean"
162
+ }, {
163
+ "name" : "updated_at",
164
+ "type" : "int"
165
+ } ]
166
+ }, {
167
+ "type" : "record",
168
+ "name" : "Media",
169
+ "fields" : [ {
170
+ "name" : "id",
171
+ "type" : "int"
172
+ }, {
173
+ "name" : "path",
174
+ "type" : "string"
175
+ }, {
176
+ "name" : "mime_type_id",
177
+ "type" : "int"
178
+ }, {
179
+ "name" : "external_url",
180
+ "type" : "string"
181
+ }, {
182
+ "name" : "caption",
183
+ "type" : "string"
184
+ }, {
185
+ "name" : "copyright",
186
+ "type" : "string"
187
+ }, {
188
+ "name" : "is_video",
189
+ "type" : "boolean"
190
+ } ]
191
+ }, {
192
+ "type" : "record",
193
+ "name" : "Personal",
194
+ "fields" : [ {
195
+ "name" : "aliases",
196
+ "type" : {
197
+ "type" : "array",
198
+ "items" : "string"
199
+ }
200
+ }, {
201
+ "name" : "bio",
202
+ "type" : "string"
203
+ }, {
204
+ "name" : "languages",
205
+ "type" : {
206
+ "type" : "array",
207
+ "items" : "string"
208
+ }
209
+ }, {
210
+ "name" : "payment_types",
211
+ "type" : {
212
+ "type" : "array",
213
+ "items" : "string"
214
+ }
215
+ }, {
216
+ "name" : "fixed_acceptance_type",
217
+ "type" : "string"
218
+ }, {
219
+ "name" : "retainer_acceptance_type",
220
+ "type" : "string"
221
+ }, {
222
+ "name" : "probono_contribution",
223
+ "type" : "int"
224
+ }, {
225
+ "name" : "free_consultation",
226
+ "type" : "int"
227
+ }, {
228
+ "name" : "cache_key",
229
+ "type" : "string"
230
+ }, {
231
+ "name" : "fees",
232
+ "type" : {
233
+ "type" : "array",
234
+ "items" : "Fee"
235
+ }
236
+ }, {
237
+ "name" : "media_thumbnails",
238
+ "type" : {
239
+ "type" : "array",
240
+ "items" : "Media"
241
+ }
242
+ }, {
243
+ "name" : "social_networks",
244
+ "type" : {
245
+ "type" : "array",
246
+ "items" : "AdditionalProfileLink"
247
+ }
248
+ } ]
249
+ }, {
250
+ "type" : "record",
251
+ "name" : "Status",
252
+ "fields" : [ {
253
+ "name" : "deceased",
254
+ "type" : "boolean"
255
+ }, {
256
+ "name" : "judge",
257
+ "type" : "boolean"
258
+ }, {
259
+ "name" : "retired",
260
+ "type" : "boolean"
261
+ }, {
262
+ "name" : "official",
263
+ "type" : "boolean"
264
+ }, {
265
+ "name" : "unverified",
266
+ "type" : "boolean"
267
+ }, {
268
+ "name" : "displayable",
269
+ "type" : "boolean"
270
+ }, {
271
+ "name" : "sanctioned",
272
+ "type" : "boolean"
273
+ }, {
274
+ "name" : "rateable",
275
+ "type" : "boolean"
276
+ } ]
277
+ }, {
278
+ "type" : "record",
279
+ "name" : "Rating",
280
+ "fields" : [ {
281
+ "name" : "overall",
282
+ "type" : "int"
283
+ }, {
284
+ "name" : "trustworthy",
285
+ "type" : "int"
286
+ }, {
287
+ "name" : "responsive",
288
+ "type" : "int"
289
+ }, {
290
+ "name" : "knowledgeable",
291
+ "type" : "int"
292
+ }, {
293
+ "name" : "communication",
294
+ "type" : "int"
295
+ } ]
296
+ }, {
297
+ "type" : "record",
298
+ "name" : "Review",
299
+ "fields" : [ {
300
+ "name" : "id",
301
+ "type" : "int"
302
+ }, {
303
+ "name" : "lawyer_id",
304
+ "type" : "int"
305
+ }, {
306
+ "name" : "title",
307
+ "type" : "string"
308
+ }, {
309
+ "name" : "body",
310
+ "type" : "string"
311
+ }, {
312
+ "name" : "recommended",
313
+ "type" : "boolean"
314
+ }, {
315
+ "name" : "specialty_id",
316
+ "type" : "int"
317
+ }, {
318
+ "name" : "anonymous",
319
+ "type" : "boolean"
320
+ }, {
321
+ "name" : "approval_status",
322
+ "type" : "int"
323
+ }, {
324
+ "name" : "display_name",
325
+ "type" : "string"
326
+ }, {
327
+ "name" : "created_at",
328
+ "type" : "int"
329
+ }, {
330
+ "name" : "updated_at",
331
+ "type" : "int"
332
+ }, {
333
+ "name" : "cache_key",
334
+ "type" : "string"
335
+ }, {
336
+ "name" : "ratings",
337
+ "type" : "Rating"
338
+ } ]
339
+ }, {
340
+ "type" : "record",
341
+ "name" : "LawyerSpecialty",
342
+ "fields" : [ {
343
+ "name" : "id",
344
+ "type" : "int"
345
+ }, {
346
+ "name" : "name",
347
+ "type" : "string"
348
+ }, {
349
+ "name" : "specialty_id",
350
+ "type" : "int"
351
+ }, {
352
+ "name" : "percent",
353
+ "type" : "int"
354
+ }, {
355
+ "name" : "start_date",
356
+ "type" : "int"
357
+ }, {
358
+ "name" : "description",
359
+ "type" : "string"
360
+ }, {
361
+ "name" : "cases",
362
+ "type" : "int"
363
+ } ]
364
+ }, {
365
+ "type" : "record",
366
+ "name" : "Lawyer",
367
+ "doc" : "The main class for this protocol",
368
+ "fields" : [ {
369
+ "name" : "id",
370
+ "type" : "int",
371
+ "doc" : "The primary key"
372
+ }, {
373
+ "name" : "firstname",
374
+ "type" : "string",
375
+ "doc" : "Their name"
376
+ }, {
377
+ "name" : "middlename",
378
+ "type" : "string"
379
+ }, {
380
+ "name" : "lastname",
381
+ "type" : "string"
382
+ }, {
383
+ "name" : "suffix",
384
+ "type" : "string"
385
+ }, {
386
+ "name" : "email_address",
387
+ "type" : "string"
388
+ }, {
389
+ "name" : "licensed_since",
390
+ "type" : "int"
391
+ }, {
392
+ "name" : "website",
393
+ "type" : "string"
394
+ }, {
395
+ "name" : "advisor_id",
396
+ "type" : "int"
397
+ }, {
398
+ "name" : "advisor_available",
399
+ "type" : "boolean"
400
+ }, {
401
+ "name" : "sanction_ids",
402
+ "type" : {
403
+ "type" : "array",
404
+ "items" : "int"
405
+ }
406
+ }, {
407
+ "name" : "licenses",
408
+ "type" : {
409
+ "type" : "array",
410
+ "items" : "License"
411
+ }
412
+ }, {
413
+ "name" : "status",
414
+ "type" : "Status"
415
+ }, {
416
+ "name" : "addresses",
417
+ "type" : {
418
+ "type" : "array",
419
+ "items" : "Address"
420
+ }
421
+ }, {
422
+ "name" : "reviews",
423
+ "type" : {
424
+ "type" : "array",
425
+ "items" : "Review"
426
+ }
427
+ }, {
428
+ "name" : "lawyer_specialties",
429
+ "type" : {
430
+ "type" : "array",
431
+ "items" : "LawyerSpecialty"
432
+ }
433
+ }, {
434
+ "name" : "personal",
435
+ "type" : "Personal"
436
+ }, {
437
+ "name" : "sanctions",
438
+ "type" : {
439
+ "type" : "array",
440
+ "items" : "Sanction"
441
+ }
442
+ }, {
443
+ "name" : "claimed_by",
444
+ "type" : "int",
445
+ "doc" : "id of claiming user *"
446
+ }, {
447
+ "name" : "headshot_url",
448
+ "type" : "string",
449
+ "doc" : "Url to their full-size headshot photo"
450
+ }, {
451
+ "name" : "avvo_rating",
452
+ "type" : "float",
453
+ "doc" : "Avvo Rating (Scale of 1-10)"
454
+ }, {
455
+ "name" : "avvo_pro",
456
+ "type" : "boolean"
457
+ }, {
458
+ "name" : "aggregate_client_review_score",
459
+ "type" : "float",
460
+ "doc" : "Average client review score (Scale of 1-5)"
461
+ }, {
462
+ "name" : "client_review_count",
463
+ "type" : "int",
464
+ "doc" : "Number of reviews the average is based upon"
465
+ }, {
466
+ "name" : "specialty_ids",
467
+ "type" : {
468
+ "type" : "array",
469
+ "items" : "int"
470
+ },
471
+ "doc" : "List of specialties this lawyer practices"
472
+ } ]
473
+ }, {
474
+ "type" : "record",
475
+ "name" : "SearchLawyer",
476
+ "doc" : "The lawyer result when performing a search",
477
+ "fields" : [ {
478
+ "name" : "id",
479
+ "type" : "int",
480
+ "doc" : "The primary key"
481
+ }, {
482
+ "name" : "firstname",
483
+ "type" : "string",
484
+ "doc" : "Their name"
485
+ }, {
486
+ "name" : "middlename",
487
+ "type" : "string"
488
+ }, {
489
+ "name" : "lastname",
490
+ "type" : "string"
491
+ }, {
492
+ "name" : "suffix",
493
+ "type" : "string"
494
+ }, {
495
+ "name" : "email_address",
496
+ "type" : "string"
497
+ }, {
498
+ "name" : "licensed_since",
499
+ "type" : "int"
500
+ }, {
501
+ "name" : "advisor_id",
502
+ "type" : "int"
503
+ }, {
504
+ "name" : "advisor_available",
505
+ "type" : "boolean"
506
+ }, {
507
+ "name" : "addresses",
508
+ "type" : {
509
+ "type" : "array",
510
+ "items" : "Address"
511
+ }
512
+ }, {
513
+ "name" : "claimed_by",
514
+ "type" : "int",
515
+ "doc" : "id of claiming user *"
516
+ }, {
517
+ "name" : "headshot_url",
518
+ "type" : "string",
519
+ "doc" : "Url to their full-size headshot photo"
520
+ }, {
521
+ "name" : "avvo_rating",
522
+ "type" : "float",
523
+ "doc" : "Avvo Rating (Scale of 1-10)"
524
+ }, {
525
+ "name" : "avvo_pro",
526
+ "type" : "boolean"
527
+ }, {
528
+ "name" : "aggregate_client_review_score",
529
+ "type" : "float",
530
+ "doc" : "Average client review score (Scale of 1-5)"
531
+ }, {
532
+ "name" : "client_review_count",
533
+ "type" : "int",
534
+ "doc" : "Number of reviews the average is based upon"
535
+ }, {
536
+ "name" : "specialty_ids",
537
+ "type" : {
538
+ "type" : "array",
539
+ "items" : "int"
540
+ },
541
+ "doc" : "List of specialties this lawyer practices"
542
+ } ]
543
+ }, {
544
+ "type" : "record",
545
+ "name" : "SearchParams",
546
+ "fields" : [ {
547
+ "name" : "loc",
548
+ "type" : "string",
549
+ "doc" : "takes a string that will be then processed through Gnomon *"
550
+ }, {
551
+ "name" : "lat",
552
+ "type" : "float",
553
+ "doc" : "latitude *"
554
+ }, {
555
+ "name" : "long",
556
+ "type" : "float",
557
+ "doc" : "longitude *"
558
+ }, {
559
+ "name" : "radius",
560
+ "type" : "float",
561
+ "doc" : "radius *"
562
+ }, {
563
+ "name" : "q",
564
+ "type" : "string",
565
+ "doc" : "this is the query interface. \"divorce\" or \"Mark Britton\" go here *"
566
+ }, {
567
+ "name" : "type",
568
+ "type" : "string",
569
+ "doc" : "this is to force what kind of search you want. The options are \"specialty\"(this is what we default to), \"location\", and \"name\" *"
570
+ }, {
571
+ "name" : "language",
572
+ "type" : "string",
573
+ "doc" : "takes a language string, such as \"English\". With the new UI, the requirement is to only filter by one language at a time *"
574
+ }, {
575
+ "name" : "has_reviews",
576
+ "type" : "boolean"
577
+ }, {
578
+ "name" : "has_endorsements",
579
+ "type" : "boolean"
580
+ }, {
581
+ "name" : "free_consultation",
582
+ "type" : "boolean"
583
+ }, {
584
+ "name" : "expertise",
585
+ "type" : "string",
586
+ "doc" : "takes an expertise name string *"
587
+ }, {
588
+ "name" : "client_ratings",
589
+ "type" : {
590
+ "type" : "array",
591
+ "items" : "int"
592
+ },
593
+ "doc" : "can take a single value, or an array of `[min, max]` where max & min are 0-5 in 0.5 increments. (Test note, the format in the URL for this is client_ratings[] =min&client_ratings[]=max) *"
594
+ }, {
595
+ "name" : "licensed_since",
596
+ "type" : {
597
+ "type" : "array",
598
+ "items" : "int"
599
+ },
600
+ "doc" : "single year value or an array of `[start, end]`. has to be a year. *"
601
+ }, {
602
+ "name" : "avvo_rating",
603
+ "type" : "string",
604
+ "doc" : "order by avvo rating. takes \"asc\" or \"desc\" *"
605
+ }, {
606
+ "name" : "client_rating",
607
+ "type" : "string",
608
+ "doc" : "order by client review rating. takes \"asc\" or \"desc\" *"
609
+ }, {
610
+ "name" : "number_of_reviews",
611
+ "type" : "string",
612
+ "doc" : "order by number of client reviews. takes \"asc\" or \"desc\" *"
613
+ }, {
614
+ "name" : "page",
615
+ "type" : "int",
616
+ "doc" : "page of results *"
617
+ }, {
618
+ "name" : "per_page",
619
+ "type" : "int",
620
+ "doc" : "results per page *"
621
+ } ]
622
+ }, {
623
+ "type" : "record",
624
+ "name" : "SearchFilters",
625
+ "fields" : [ {
626
+ "name" : "language",
627
+ "type" : {
628
+ "type" : "array",
629
+ "items" : "string"
630
+ }
631
+ }, {
632
+ "name" : "has_reviews",
633
+ "type" : {
634
+ "type" : "array",
635
+ "items" : "boolean"
636
+ }
637
+ }, {
638
+ "name" : "has_endorsements",
639
+ "type" : {
640
+ "type" : "array",
641
+ "items" : "boolean"
642
+ }
643
+ }, {
644
+ "name" : "free_consultation",
645
+ "type" : {
646
+ "type" : "array",
647
+ "items" : "boolean"
648
+ }
649
+ }, {
650
+ "name" : "expertise",
651
+ "type" : {
652
+ "type" : "array",
653
+ "items" : "string"
654
+ }
655
+ }, {
656
+ "name" : "client_reviews",
657
+ "type" : {
658
+ "type" : "array",
659
+ "items" : "float"
660
+ }
661
+ } ]
662
+ }, {
663
+ "type" : "record",
664
+ "name" : "SearchLocation",
665
+ "fields" : [ {
666
+ "name" : "location_id",
667
+ "type" : "int"
668
+ }, {
669
+ "name" : "lat",
670
+ "type" : "float"
671
+ }, {
672
+ "name" : "long",
673
+ "type" : "float"
674
+ }, {
675
+ "name" : "type",
676
+ "type" : "string"
677
+ }, {
678
+ "name" : "surrounding_location_ids",
679
+ "type" : {
680
+ "type" : "array",
681
+ "items" : "int"
682
+ }
683
+ } ]
684
+ }, {
685
+ "type" : "record",
686
+ "name" : "SearchStats",
687
+ "fields" : [ {
688
+ "name" : "review_count",
689
+ "type" : "int"
690
+ }, {
691
+ "name" : "average_review_rating",
692
+ "type" : "float"
693
+ } ]
694
+ }, {
695
+ "type" : "record",
696
+ "name" : "SearchContext",
697
+ "fields" : [ {
698
+ "name" : "search",
699
+ "type" : "string"
700
+ }, {
701
+ "name" : "specialty",
702
+ "type" : "int"
703
+ }, {
704
+ "name" : "name_suggestion",
705
+ "type" : "boolean"
706
+ }, {
707
+ "name" : "filters",
708
+ "type" : "SearchFilters"
709
+ }, {
710
+ "name" : "location",
711
+ "type" : "SearchLocation"
712
+ }, {
713
+ "name" : "stats",
714
+ "type" : "SearchStats"
715
+ }, {
716
+ "name" : "pls_lawyer_ids",
717
+ "type" : {
718
+ "type" : "array",
719
+ "items" : "int"
720
+ }
721
+ } ]
722
+ }, {
723
+ "type" : "record",
724
+ "name" : "SearchMetadata",
725
+ "fields" : [ {
726
+ "name" : "context",
727
+ "type" : "SearchContext"
728
+ }, {
729
+ "name" : "status",
730
+ "type" : "int"
731
+ }, {
732
+ "name" : "current_page",
733
+ "type" : "int"
734
+ }, {
735
+ "name" : "per_page",
736
+ "type" : "int"
737
+ }, {
738
+ "name" : "total_pages",
739
+ "type" : "int"
740
+ }, {
741
+ "name" : "total_entries",
742
+ "type" : "int"
743
+ } ]
744
+ }, {
745
+ "type" : "record",
746
+ "name" : "SearchResult",
747
+ "fields" : [ {
748
+ "name" : "lawyers",
749
+ "type" : {
750
+ "type" : "array",
751
+ "items" : "SearchLawyer"
752
+ }
753
+ }, {
754
+ "name" : "meta",
755
+ "type" : "SearchMetadata"
756
+ } ]
757
+ } ],
758
+ "messages" : {
759
+ "index" : {
760
+ "doc" : "Look up many lawyers in bulk",
761
+ "request" : [ ],
762
+ "response" : {
763
+ "type" : "array",
764
+ "items" : "Lawyer"
765
+ }
766
+ },
767
+ "show" : {
768
+ "doc" : "Look up a single lawyer by id",
769
+ "request" : [ {
770
+ "name" : "id",
771
+ "type" : "int"
772
+ } ],
773
+ "response" : {
774
+ "type" : "array",
775
+ "items" : "Lawyer"
776
+ }
777
+ },
778
+ "search" : {
779
+ "doc" : "Look up a single lawyer by id",
780
+ "request" : [ {
781
+ "name" : "params",
782
+ "type" : "SearchParams"
783
+ } ],
784
+ "response" : "SearchResult"
785
+ }
786
+ }
787
+ }