Skip to content

Commit 03917c7

Browse files
committed
chore(api): updated with location details
1 parent 1b3869e commit 03917c7

File tree

4 files changed

+550
-8
lines changed

4 files changed

+550
-8
lines changed

docs/api_data.js

Lines changed: 273 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1724,6 +1724,250 @@ define({ "api": [
17241724
]
17251725
}
17261726
},
1727+
{
1728+
"type": "Delete",
1729+
"url": "/crm/client/:clientid/location/:locationid",
1730+
"title": "Delete Location",
1731+
"name": "DeleteClientLocation",
1732+
"order": "5",
1733+
"group": "CRM_Location",
1734+
"version": "1.0.0",
1735+
"examples": [
1736+
{
1737+
"title": "CURL Example",
1738+
"content": "curl -A YourCompany -u admin:password -X \"DELETE\" https://service.formitize.com/api/rest/v2/crm/client/77/location/80",
1739+
"type": "json"
1740+
}
1741+
],
1742+
"success": {
1743+
"examples": [
1744+
{
1745+
"title": "Response Body Example:",
1746+
"content": "{\n \"payload\": {\n \"deleted\": [\"80\"]\n }\n}",
1747+
"type": "json"
1748+
}
1749+
]
1750+
},
1751+
"filename": "app/system/class/api/rest/v1/crm/client/_apidoc.location.js",
1752+
"groupTitle": "CRM_Location"
1753+
},
1754+
{
1755+
"type": "Delete",
1756+
"url": "/crm/client/:clientid/location/all",
1757+
"title": "Delete All Locations",
1758+
"name": "DeleteClientLocationAll",
1759+
"order": "5",
1760+
"group": "CRM_Location",
1761+
"version": "1.0.0",
1762+
"examples": [
1763+
{
1764+
"title": "CURL Example",
1765+
"content": "curl -A YourCompany -u admin:password -X \"DELETE\" https://service.formitize.com/api/rest/v2/crm/client/77/location/all",
1766+
"type": "json"
1767+
}
1768+
],
1769+
"success": {
1770+
"examples": [
1771+
{
1772+
"title": "Response Body Example:",
1773+
"content": "{\n \"payload\": {\n \"deleted\": [\"80\", \"81\", \"82\", \"83\"]\n }\n}",
1774+
"type": "json"
1775+
}
1776+
]
1777+
},
1778+
"filename": "app/system/class/api/rest/v1/crm/client/_apidoc.location.js",
1779+
"groupTitle": "CRM_Location"
1780+
},
1781+
{
1782+
"type": "Get",
1783+
"url": "/crm/client/:clientid/location/:locationid",
1784+
"title": "Get Location",
1785+
"name": "GetClientLocation",
1786+
"order": "2",
1787+
"group": "CRM_Location",
1788+
"version": "1.0.0",
1789+
"examples": [
1790+
{
1791+
"title": "CURL Example",
1792+
"content": "curl -A YourCompany -u admin:password -X \"GET\" https://service.formitize.com/api/rest/v2/crm/client/77/location/80",
1793+
"type": "json"
1794+
}
1795+
],
1796+
"success": {
1797+
"examples": [
1798+
{
1799+
"title": "Response Body Example:",
1800+
"content": "{\n \"payload\": {\n \"id\": \"80\",\n \"street1\": \"123 Homer Street\",\n \"street2\": \"\",\n \"city\": \"Sydney\",\n \"state\": \"NSW\",\n \"country\": \"Australia\"\n }\n}",
1801+
"type": "json"
1802+
}
1803+
]
1804+
},
1805+
"filename": "app/system/class/api/rest/v1/crm/client/_apidoc.location.js",
1806+
"groupTitle": "CRM_Location"
1807+
},
1808+
{
1809+
"type": "Get",
1810+
"url": "/crm/client/:clientid/location/",
1811+
"title": "Get Locations",
1812+
"name": "GetClientLocations",
1813+
"order": "2",
1814+
"group": "CRM_Location",
1815+
"version": "1.0.0",
1816+
"examples": [
1817+
{
1818+
"title": "CURL Example",
1819+
"content": "curl -A YourCompany -u admin:password -X \"GET\" https://service.formitize.com/api/rest/v2/crm/client/77/locations",
1820+
"type": "json"
1821+
}
1822+
],
1823+
"success": {
1824+
"examples": [
1825+
{
1826+
"title": "Response Body Example:",
1827+
"content": "{\n \"payload\": [{\n \"id\": \"80\",\n \"street1\": \"123 Homer Street\",\n \"street2\": \"\",\n \"city\": \"Sydney\",\n \"state\": \"NSW\",\n \"country\": \"Australia\"\n },\n {\n \"id\": \"84\",\n \"street1\": \"456 Homer Street\",\n \"street2\": \"\",\n \"city\": \"Sydney\",\n \"state\": \"NSW\",\n \"country\": \"Australia\"\n },\n ...]\n}",
1828+
"type": "json"
1829+
}
1830+
]
1831+
},
1832+
"filename": "app/system/class/api/rest/v1/crm/client/_apidoc.location.js",
1833+
"groupTitle": "CRM_Location"
1834+
},
1835+
{
1836+
"type": "post",
1837+
"url": "/crm/client/:clientid/location",
1838+
"title": "Add Location",
1839+
"name": "PostAddClientLocation",
1840+
"order": "1",
1841+
"group": "CRM_Location",
1842+
"version": "1.0.0",
1843+
"parameter": {
1844+
"fields": {
1845+
"Location Fields": [
1846+
{
1847+
"group": "Location Fields",
1848+
"type": "String",
1849+
"optional": true,
1850+
"field": "street1",
1851+
"description": "<p>Street 1 address.</p>"
1852+
},
1853+
{
1854+
"group": "Location Fields",
1855+
"type": "String",
1856+
"optional": true,
1857+
"field": "street2",
1858+
"description": "<p>Street 2 address.</p>"
1859+
},
1860+
{
1861+
"group": "Location Fields",
1862+
"type": "String",
1863+
"optional": true,
1864+
"field": "city",
1865+
"description": "<p>City address.</p>"
1866+
},
1867+
{
1868+
"group": "Location Fields",
1869+
"type": "String",
1870+
"optional": true,
1871+
"field": "state",
1872+
"description": "<p>State address.</p>"
1873+
},
1874+
{
1875+
"group": "Location Fields",
1876+
"type": "String",
1877+
"optional": true,
1878+
"field": "postcode",
1879+
"description": "<p>Postcode address.</p>"
1880+
},
1881+
{
1882+
"group": "Location Fields",
1883+
"type": "String",
1884+
"optional": true,
1885+
"field": "country",
1886+
"description": "<p>Country address.</p>"
1887+
}
1888+
]
1889+
}
1890+
},
1891+
"success": {
1892+
"examples": [
1893+
{
1894+
"title": "Response Body Example:",
1895+
"content": "{\n \"payload\": {\n \"id\": \"80\",\n }\n}",
1896+
"type": "json"
1897+
}
1898+
]
1899+
},
1900+
"filename": "app/system/class/api/rest/v1/crm/client/_apidoc.location.js",
1901+
"groupTitle": "CRM_Location"
1902+
},
1903+
{
1904+
"type": "post",
1905+
"url": "/crm/client/:clientid/location/:locationid",
1906+
"title": "Edit Location",
1907+
"name": "PostEditClientLocation",
1908+
"order": "2",
1909+
"group": "CRM_Location",
1910+
"version": "1.0.0",
1911+
"parameter": {
1912+
"fields": {
1913+
"Location Fields": [
1914+
{
1915+
"group": "Location Fields",
1916+
"type": "String",
1917+
"optional": true,
1918+
"field": "street1",
1919+
"description": "<p>Street 1 address.</p>"
1920+
},
1921+
{
1922+
"group": "Location Fields",
1923+
"type": "String",
1924+
"optional": true,
1925+
"field": "street2",
1926+
"description": "<p>Street 2 address.</p>"
1927+
},
1928+
{
1929+
"group": "Location Fields",
1930+
"type": "String",
1931+
"optional": true,
1932+
"field": "city",
1933+
"description": "<p>City address.</p>"
1934+
},
1935+
{
1936+
"group": "Location Fields",
1937+
"type": "String",
1938+
"optional": true,
1939+
"field": "state",
1940+
"description": "<p>State address.</p>"
1941+
},
1942+
{
1943+
"group": "Location Fields",
1944+
"type": "String",
1945+
"optional": true,
1946+
"field": "postcode",
1947+
"description": "<p>Postcode address.</p>"
1948+
},
1949+
{
1950+
"group": "Location Fields",
1951+
"type": "String",
1952+
"optional": true,
1953+
"field": "country",
1954+
"description": "<p>Country address.</p>"
1955+
}
1956+
]
1957+
}
1958+
},
1959+
"success": {
1960+
"examples": [
1961+
{
1962+
"title": "Response Body Example:",
1963+
"content": "{\n \"payload\": {\n \"id\": \"80\",\n }\n}",
1964+
"type": "json"
1965+
}
1966+
]
1967+
},
1968+
"filename": "app/system/class/api/rest/v1/crm/client/_apidoc.location.js",
1969+
"groupTitle": "CRM_Location"
1970+
},
17271971
{
17281972
"type": "get",
17291973
"url": "/database/list",
@@ -1946,14 +2190,41 @@ define({ "api": [
19462190
"examples": [
19472191
{
19482192
"title": "CURL Response",
1949-
"content": "{\n \"payload\": {\n \"id\": \"245\",\n \"maintenanceID\": \"0\",\n \"jobNumber\": \"245\",\n \"orderNumber\": \"\",\n \"title\": \"Test B\",\n \"forms\": {\n \"2932\": {\n \"id\": \"2932\",\n \"title\": \"Features Test\"\n }\n },\n \"location\": \"\",\n \"description\": \"\",\n \"dueDate\": \"1599688800\",\n \"assignedTo\": \"0\",\n \"priority\": \"0\",\n \"status\": \"1\",\n \"duration\": \"136800\",\n \"statusLabel\": \"Created\"\n }\n}",
2193+
"content": "{\n \"payload\": {\n \"id\": \"245\",\n \"maintenanceID\": \"0\",\n \"jobNumber\": \"245\",\n \"orderNumber\": \"\",\n \"invoiceID\": \"0\",\n \"invoiceNumber\": \"\",\n \"title\": \"Test B\",\n \"forms\": {\n \"2932\": {\n \"id\": \"2932\",\n \"title\": \"Features Test\"\n }\n },\n \"location\": \"\",\n \"description\": \"\",\n \"dueDate\": \"1599688800\",\n \"assignedTo\": \"0\",\n \"priority\": \"0\",\n \"status\": \"1\",\n \"duration\": \"136800\",\n \"statusLabel\": \"Created\"\n }\n}",
19502194
"type": "JSON"
19512195
}
19522196
]
19532197
},
19542198
"filename": "app/system/class/api/rest/v1/job/_apidoc.js",
19552199
"groupTitle": "Job"
19562200
},
2201+
{
2202+
"type": "get",
2203+
"url": "/job/:id/history",
2204+
"title": "Get Job History",
2205+
"name": "GetJobHistory",
2206+
"group": "Job",
2207+
"order": "6_",
2208+
"examples": [
2209+
{
2210+
"title": "CURL Example",
2211+
"content": "curl -A YourCompany -u admin:password -X \"GET\" https://service.formitize.com/api/rest/v2/job/:id/history/",
2212+
"type": "json"
2213+
}
2214+
],
2215+
"success": {
2216+
"examples": [
2217+
{
2218+
"title": "Success-Response:",
2219+
"content": "HTTP/1.1 200 OK\n{\n \"payload\": [{\n \"text\": \"Created Job.\",\n \"startDate\": \"2021-04-28T15:57:46+10:00\",\n \"endDate\": \"2021-04-28T15:57:46+10:00\",\n }]\n}",
2220+
"type": "json"
2221+
}
2222+
]
2223+
},
2224+
"version": "0.0.0",
2225+
"filename": "app/system/class/api/rest/v1/job/_apidoc.job.history.js",
2226+
"groupTitle": "Job"
2227+
},
19572228
{
19582229
"type": "get",
19592230
"url": "/job/",
@@ -1974,7 +2245,7 @@ define({ "api": [
19742245
"examples": [
19752246
{
19762247
"title": "CURL Response",
1977-
"content": "{\n \"payload\": {\n \"5555\": {\n \"id\": \"5555\",\n \"maintenanceID\": \"0\",\n \"jobNumber\": \"\",\n \"orderNumber\": \"\",\n \"title\": \"Person A\",\n \"forms\": {\n \"2932\": {\n \"id\": \"2932\",\n \"title\": \"Features Test\"\n }\n },\n \"location\": \"123 Street\",\n \"description\": \"\",\n \"dueDate\": \"1417139760\",\n \"assignedTo\": \"2251\",\n \"priority\": \"0\",\n \"status\": \"4\",\n \"duration\": \"3600\",\n \"statusLabel\": \"Completed\"\n }\n }\n}",
2248+
"content": "{\n \"payload\": {\n \"5555\": {\n \"id\": \"5555\",\n \"maintenanceID\": \"0\",\n \"jobNumber\": \"\",\n \"orderNumber\": \"\",\n \"invoiceID\": \"0\",\n \"invoiceNumber\": \"\",\n \"title\": \"Person A\",\n \"forms\": {\n \"2932\": {\n \"id\": \"2932\",\n \"title\": \"Features Test\"\n }\n },\n \"location\": \"123 Street\",\n \"description\": \"\",\n \"dueDate\": \"1417139760\",\n \"assignedTo\": \"2251\",\n \"priority\": \"0\",\n \"status\": \"4\",\n \"duration\": \"3600\",\n \"statusLabel\": \"Completed\"\n }\n }\n}",
19782249
"type": "JSON"
19792250
}
19802251
]

0 commit comments

Comments
 (0)