Difference between revisions of "Get Company"
From MyMobileWorkers API
(Created page with "== Summary == {| border="1" class="wikitable" ! Get Company ! colspan="2" | |- ! URL | colspan="2" | http://:base_url/:api_path/:version/companies/company |- ! Type | colsp...") |
(→Response Parameters) |
||
| Line 85: | Line 85: | ||
! attachments | ! attachments | ||
| Array of attachments | | Array of attachments | ||
| + | |- | ||
| + | |} | ||
| + | === Attachments array === | ||
| + | |||
| + | {| border="1" class="wikitable" | ||
| + | |||
| + | ! Field | ||
| + | ! Description | ||
| + | |- | ||
| + | ! file | ||
| + | | Filename. To hotlink use http://live.mymobileworkers.com/uploads/company_uploads/"file" | ||
| + | |- | ||
| + | ! comment | ||
| + | | Comment | ||
| + | |- | ||
| + | ! created_at | ||
| + | | Date attachment was uploaded | ||
|- | |- | ||
|} | |} | ||
Revision as of 14:03, 15 May 2013
Contents |
Summary
| Get Company | ||
|---|---|---|
| URL | http://:base_url/:api_path/:version/companies/company | |
| Type | GET | |
| Params: | api_key | required |
| Response | JSON | |
Returns company data and company attachments. Company attachments are separate from job attachments. Along with the basic information on the company you get a few bits related to their customisations (colour scheme etc) which may be useful for developing bespoke applications.
Response Parameters
| Field | Description |
|---|---|
| name | Company Name |
| contact_name | Contact Name |
| contact_email | Contact Email |
| created_at | Date company signed up to MMW |
| color_1 | One of the colours used to customise the portal |
| color_2 | One of the colours used to customise the portal |
| color_3 | One of the colours used to customise the portal |
| locale | Currently not used |
| logo_path | Raw filename of companies logo. To hotlink use http://live.mymobileworkers.com/uploads/logos/"logo_path" |
| vehicle_check_disclaimer | Vehicle Check Disclaimer |
| company_registration_number | VAT number if entered |
| subdomain | If customer portal is enabled companies customers can visit http://"subdomain".mymobileworkers.com |
| address_1 | Address line 1 |
| address_2 | Address line 2 |
| address_3 | Address line 3 |
| address_4 | Address line 4 |
| postcode | Postcode |
| vat_rate | VAT percentage (1.2 = 20% etc.) |
| attachments | Array of attachments |
Attachments array
| Field | Description |
|---|---|
| file | Filename. To hotlink use http://live.mymobileworkers.com/uploads/company_uploads/"file" |
| comment | Comment |
| created_at | Date attachment was uploaded |
Example response
[ {"username":"USER1","email":"ryanmt@nospam.com","color":"D7C863","engineer_registration_number":null}, {"username":"USER2","email":"bobbob@nospam.com","color":"97326A","engineer_registration_number":null}, {"username":"USER3","email":"sdfasdf@nospam.com","color":"56500D","engineer_registration_number":null}, {"username":"USER4","email":"asdsdf@nospam.com","color":"C1C355","engineer_registration_number":null}, {"username":"USER5","email":"asdfds@nospam.com","color":"FA556A","engineer_registration_number":null} ]
Example curl request
http://live.mymobileworkers.com:8080/api/1/mobile_users?api_key=YOURAPIKEY