@deepintel-ltd/farmpro-contracts 1.5.13 → 1.5.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/dist/index.d.ts +5 -1
  2. package/dist/index.d.ts.map +1 -1
  3. package/dist/index.js +4 -0
  4. package/dist/routes/agents.routes.d.ts +623 -0
  5. package/dist/routes/agents.routes.d.ts.map +1 -1
  6. package/dist/routes/agents.routes.js +18 -1
  7. package/dist/routes/auth.routes.d.ts +509 -0
  8. package/dist/routes/auth.routes.d.ts.map +1 -1
  9. package/dist/routes/auth.routes.js +26 -2
  10. package/dist/routes/field-monitoring.routes.d.ts +18 -18
  11. package/dist/routes/index.d.ts +6 -0
  12. package/dist/routes/index.d.ts.map +1 -1
  13. package/dist/routes/index.js +4 -0
  14. package/dist/routes/payments.routes.d.ts +1851 -0
  15. package/dist/routes/payments.routes.d.ts.map +1 -0
  16. package/dist/routes/payments.routes.js +91 -0
  17. package/dist/routes/subscriptions.routes.d.ts +3151 -0
  18. package/dist/routes/subscriptions.routes.d.ts.map +1 -0
  19. package/dist/routes/subscriptions.routes.js +155 -0
  20. package/dist/schemas/agents.schemas.d.ts +916 -0
  21. package/dist/schemas/agents.schemas.d.ts.map +1 -1
  22. package/dist/schemas/agents.schemas.js +34 -0
  23. package/dist/schemas/auth.schemas.d.ts +306 -0
  24. package/dist/schemas/auth.schemas.d.ts.map +1 -1
  25. package/dist/schemas/auth.schemas.js +26 -0
  26. package/dist/schemas/field-monitoring.schemas.d.ts +18 -18
  27. package/dist/schemas/payments.schemas.d.ts +822 -0
  28. package/dist/schemas/payments.schemas.d.ts.map +1 -0
  29. package/dist/schemas/payments.schemas.js +105 -0
  30. package/dist/schemas/subscriptions.schemas.d.ts +1344 -0
  31. package/dist/schemas/subscriptions.schemas.d.ts.map +1 -0
  32. package/dist/schemas/subscriptions.schemas.js +150 -0
  33. package/package.json +1 -1
@@ -1537,5 +1537,628 @@ export declare const agentsRouter: {
1537
1537
  }>;
1538
1538
  };
1539
1539
  };
1540
+ generateSurveyGeoJSON: {
1541
+ summary: "Generate GeoJSON from survey document";
1542
+ description: "Upload a survey document (PDF or image) and generate standardized GeoJSON. The agent intelligently extracts survey data, handles errors, and makes approximations when needed to create accurate geospatial boundaries.";
1543
+ method: "POST";
1544
+ contentType: "multipart/form-data";
1545
+ body: z.ZodObject<{
1546
+ file: z.ZodAny;
1547
+ }, "strip", z.ZodTypeAny, {
1548
+ file?: any;
1549
+ }, {
1550
+ file?: any;
1551
+ }>;
1552
+ path: "/agents/survey/geojson";
1553
+ responses: {
1554
+ 200: z.ZodObject<{
1555
+ data: z.ZodObject<{
1556
+ type: z.ZodLiteral<string>;
1557
+ id: z.ZodString;
1558
+ attributes: z.ZodObject<{
1559
+ geojson: z.ZodObject<{
1560
+ type: z.ZodLiteral<"FeatureCollection">;
1561
+ crs: z.ZodObject<{
1562
+ type: z.ZodLiteral<"name">;
1563
+ properties: z.ZodObject<{
1564
+ name: z.ZodString;
1565
+ }, "strip", z.ZodTypeAny, {
1566
+ name: string;
1567
+ }, {
1568
+ name: string;
1569
+ }>;
1570
+ }, "strip", z.ZodTypeAny, {
1571
+ type: "name";
1572
+ properties: {
1573
+ name: string;
1574
+ };
1575
+ }, {
1576
+ type: "name";
1577
+ properties: {
1578
+ name: string;
1579
+ };
1580
+ }>;
1581
+ features: z.ZodArray<z.ZodObject<{
1582
+ type: z.ZodLiteral<"Feature">;
1583
+ properties: z.ZodObject<{
1584
+ name: z.ZodString;
1585
+ area_hectares: z.ZodNumber;
1586
+ data_note: z.ZodOptional<z.ZodString>;
1587
+ }, "strip", z.ZodTypeAny, {
1588
+ name: string;
1589
+ area_hectares: number;
1590
+ data_note?: string | undefined;
1591
+ }, {
1592
+ name: string;
1593
+ area_hectares: number;
1594
+ data_note?: string | undefined;
1595
+ }>;
1596
+ geometry: z.ZodObject<{
1597
+ type: z.ZodLiteral<"Polygon">;
1598
+ coordinates: z.ZodArray<z.ZodArray<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>, "many">, "many">;
1599
+ }, "strip", z.ZodTypeAny, {
1600
+ type: "Polygon";
1601
+ coordinates: [number, number][][];
1602
+ }, {
1603
+ type: "Polygon";
1604
+ coordinates: [number, number][][];
1605
+ }>;
1606
+ }, "strip", z.ZodTypeAny, {
1607
+ type: "Feature";
1608
+ geometry: {
1609
+ type: "Polygon";
1610
+ coordinates: [number, number][][];
1611
+ };
1612
+ properties: {
1613
+ name: string;
1614
+ area_hectares: number;
1615
+ data_note?: string | undefined;
1616
+ };
1617
+ }, {
1618
+ type: "Feature";
1619
+ geometry: {
1620
+ type: "Polygon";
1621
+ coordinates: [number, number][][];
1622
+ };
1623
+ properties: {
1624
+ name: string;
1625
+ area_hectares: number;
1626
+ data_note?: string | undefined;
1627
+ };
1628
+ }>, "many">;
1629
+ }, "strip", z.ZodTypeAny, {
1630
+ type: "FeatureCollection";
1631
+ crs: {
1632
+ type: "name";
1633
+ properties: {
1634
+ name: string;
1635
+ };
1636
+ };
1637
+ features: {
1638
+ type: "Feature";
1639
+ geometry: {
1640
+ type: "Polygon";
1641
+ coordinates: [number, number][][];
1642
+ };
1643
+ properties: {
1644
+ name: string;
1645
+ area_hectares: number;
1646
+ data_note?: string | undefined;
1647
+ };
1648
+ }[];
1649
+ }, {
1650
+ type: "FeatureCollection";
1651
+ crs: {
1652
+ type: "name";
1653
+ properties: {
1654
+ name: string;
1655
+ };
1656
+ };
1657
+ features: {
1658
+ type: "Feature";
1659
+ geometry: {
1660
+ type: "Polygon";
1661
+ coordinates: [number, number][][];
1662
+ };
1663
+ properties: {
1664
+ name: string;
1665
+ area_hectares: number;
1666
+ data_note?: string | undefined;
1667
+ };
1668
+ }[];
1669
+ }>;
1670
+ processingNotes: z.ZodOptional<z.ZodString>;
1671
+ }, "strip", z.ZodTypeAny, {
1672
+ geojson: {
1673
+ type: "FeatureCollection";
1674
+ crs: {
1675
+ type: "name";
1676
+ properties: {
1677
+ name: string;
1678
+ };
1679
+ };
1680
+ features: {
1681
+ type: "Feature";
1682
+ geometry: {
1683
+ type: "Polygon";
1684
+ coordinates: [number, number][][];
1685
+ };
1686
+ properties: {
1687
+ name: string;
1688
+ area_hectares: number;
1689
+ data_note?: string | undefined;
1690
+ };
1691
+ }[];
1692
+ };
1693
+ processingNotes?: string | undefined;
1694
+ }, {
1695
+ geojson: {
1696
+ type: "FeatureCollection";
1697
+ crs: {
1698
+ type: "name";
1699
+ properties: {
1700
+ name: string;
1701
+ };
1702
+ };
1703
+ features: {
1704
+ type: "Feature";
1705
+ geometry: {
1706
+ type: "Polygon";
1707
+ coordinates: [number, number][][];
1708
+ };
1709
+ properties: {
1710
+ name: string;
1711
+ area_hectares: number;
1712
+ data_note?: string | undefined;
1713
+ };
1714
+ }[];
1715
+ };
1716
+ processingNotes?: string | undefined;
1717
+ }>;
1718
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1719
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1720
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1721
+ }, "strip", z.ZodTypeAny, {
1722
+ type: string;
1723
+ id: string;
1724
+ attributes: {
1725
+ geojson: {
1726
+ type: "FeatureCollection";
1727
+ crs: {
1728
+ type: "name";
1729
+ properties: {
1730
+ name: string;
1731
+ };
1732
+ };
1733
+ features: {
1734
+ type: "Feature";
1735
+ geometry: {
1736
+ type: "Polygon";
1737
+ coordinates: [number, number][][];
1738
+ };
1739
+ properties: {
1740
+ name: string;
1741
+ area_hectares: number;
1742
+ data_note?: string | undefined;
1743
+ };
1744
+ }[];
1745
+ };
1746
+ processingNotes?: string | undefined;
1747
+ };
1748
+ relationships?: Record<string, unknown> | undefined;
1749
+ links?: Record<string, string> | undefined;
1750
+ meta?: Record<string, unknown> | undefined;
1751
+ }, {
1752
+ type: string;
1753
+ id: string;
1754
+ attributes: {
1755
+ geojson: {
1756
+ type: "FeatureCollection";
1757
+ crs: {
1758
+ type: "name";
1759
+ properties: {
1760
+ name: string;
1761
+ };
1762
+ };
1763
+ features: {
1764
+ type: "Feature";
1765
+ geometry: {
1766
+ type: "Polygon";
1767
+ coordinates: [number, number][][];
1768
+ };
1769
+ properties: {
1770
+ name: string;
1771
+ area_hectares: number;
1772
+ data_note?: string | undefined;
1773
+ };
1774
+ }[];
1775
+ };
1776
+ processingNotes?: string | undefined;
1777
+ };
1778
+ relationships?: Record<string, unknown> | undefined;
1779
+ links?: Record<string, string> | undefined;
1780
+ meta?: Record<string, unknown> | undefined;
1781
+ }>;
1782
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
1783
+ type: z.ZodString;
1784
+ id: z.ZodString;
1785
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1786
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1787
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1788
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1789
+ }, "strip", z.ZodTypeAny, {
1790
+ type: string;
1791
+ id: string;
1792
+ attributes?: Record<string, unknown> | undefined;
1793
+ relationships?: Record<string, unknown> | undefined;
1794
+ links?: Record<string, string> | undefined;
1795
+ meta?: Record<string, unknown> | undefined;
1796
+ }, {
1797
+ type: string;
1798
+ id: string;
1799
+ attributes?: Record<string, unknown> | undefined;
1800
+ relationships?: Record<string, unknown> | undefined;
1801
+ links?: Record<string, string> | undefined;
1802
+ meta?: Record<string, unknown> | undefined;
1803
+ }>, "many">>;
1804
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1805
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1806
+ }, "strip", z.ZodTypeAny, {
1807
+ data: {
1808
+ type: string;
1809
+ id: string;
1810
+ attributes: {
1811
+ geojson: {
1812
+ type: "FeatureCollection";
1813
+ crs: {
1814
+ type: "name";
1815
+ properties: {
1816
+ name: string;
1817
+ };
1818
+ };
1819
+ features: {
1820
+ type: "Feature";
1821
+ geometry: {
1822
+ type: "Polygon";
1823
+ coordinates: [number, number][][];
1824
+ };
1825
+ properties: {
1826
+ name: string;
1827
+ area_hectares: number;
1828
+ data_note?: string | undefined;
1829
+ };
1830
+ }[];
1831
+ };
1832
+ processingNotes?: string | undefined;
1833
+ };
1834
+ relationships?: Record<string, unknown> | undefined;
1835
+ links?: Record<string, string> | undefined;
1836
+ meta?: Record<string, unknown> | undefined;
1837
+ };
1838
+ links?: Record<string, string> | undefined;
1839
+ meta?: Record<string, unknown> | undefined;
1840
+ included?: {
1841
+ type: string;
1842
+ id: string;
1843
+ attributes?: Record<string, unknown> | undefined;
1844
+ relationships?: Record<string, unknown> | undefined;
1845
+ links?: Record<string, string> | undefined;
1846
+ meta?: Record<string, unknown> | undefined;
1847
+ }[] | undefined;
1848
+ }, {
1849
+ data: {
1850
+ type: string;
1851
+ id: string;
1852
+ attributes: {
1853
+ geojson: {
1854
+ type: "FeatureCollection";
1855
+ crs: {
1856
+ type: "name";
1857
+ properties: {
1858
+ name: string;
1859
+ };
1860
+ };
1861
+ features: {
1862
+ type: "Feature";
1863
+ geometry: {
1864
+ type: "Polygon";
1865
+ coordinates: [number, number][][];
1866
+ };
1867
+ properties: {
1868
+ name: string;
1869
+ area_hectares: number;
1870
+ data_note?: string | undefined;
1871
+ };
1872
+ }[];
1873
+ };
1874
+ processingNotes?: string | undefined;
1875
+ };
1876
+ relationships?: Record<string, unknown> | undefined;
1877
+ links?: Record<string, string> | undefined;
1878
+ meta?: Record<string, unknown> | undefined;
1879
+ };
1880
+ links?: Record<string, string> | undefined;
1881
+ meta?: Record<string, unknown> | undefined;
1882
+ included?: {
1883
+ type: string;
1884
+ id: string;
1885
+ attributes?: Record<string, unknown> | undefined;
1886
+ relationships?: Record<string, unknown> | undefined;
1887
+ links?: Record<string, string> | undefined;
1888
+ meta?: Record<string, unknown> | undefined;
1889
+ }[] | undefined;
1890
+ }>;
1891
+ 400: z.ZodObject<{
1892
+ errors: z.ZodArray<z.ZodObject<{
1893
+ id: z.ZodOptional<z.ZodString>;
1894
+ links: z.ZodOptional<z.ZodObject<{
1895
+ about: z.ZodOptional<z.ZodString>;
1896
+ }, "strip", z.ZodTypeAny, {
1897
+ about?: string | undefined;
1898
+ }, {
1899
+ about?: string | undefined;
1900
+ }>>;
1901
+ status: z.ZodOptional<z.ZodString>;
1902
+ code: z.ZodOptional<z.ZodString>;
1903
+ title: z.ZodOptional<z.ZodString>;
1904
+ detail: z.ZodOptional<z.ZodString>;
1905
+ source: z.ZodOptional<z.ZodObject<{
1906
+ pointer: z.ZodOptional<z.ZodString>;
1907
+ parameter: z.ZodOptional<z.ZodString>;
1908
+ }, "strip", z.ZodTypeAny, {
1909
+ pointer?: string | undefined;
1910
+ parameter?: string | undefined;
1911
+ }, {
1912
+ pointer?: string | undefined;
1913
+ parameter?: string | undefined;
1914
+ }>>;
1915
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1916
+ }, "strip", z.ZodTypeAny, {
1917
+ status?: string | undefined;
1918
+ code?: string | undefined;
1919
+ id?: string | undefined;
1920
+ links?: {
1921
+ about?: string | undefined;
1922
+ } | undefined;
1923
+ meta?: Record<string, unknown> | undefined;
1924
+ title?: string | undefined;
1925
+ detail?: string | undefined;
1926
+ source?: {
1927
+ pointer?: string | undefined;
1928
+ parameter?: string | undefined;
1929
+ } | undefined;
1930
+ }, {
1931
+ status?: string | undefined;
1932
+ code?: string | undefined;
1933
+ id?: string | undefined;
1934
+ links?: {
1935
+ about?: string | undefined;
1936
+ } | undefined;
1937
+ meta?: Record<string, unknown> | undefined;
1938
+ title?: string | undefined;
1939
+ detail?: string | undefined;
1940
+ source?: {
1941
+ pointer?: string | undefined;
1942
+ parameter?: string | undefined;
1943
+ } | undefined;
1944
+ }>, "many">;
1945
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1946
+ }, "strip", z.ZodTypeAny, {
1947
+ errors: {
1948
+ status?: string | undefined;
1949
+ code?: string | undefined;
1950
+ id?: string | undefined;
1951
+ links?: {
1952
+ about?: string | undefined;
1953
+ } | undefined;
1954
+ meta?: Record<string, unknown> | undefined;
1955
+ title?: string | undefined;
1956
+ detail?: string | undefined;
1957
+ source?: {
1958
+ pointer?: string | undefined;
1959
+ parameter?: string | undefined;
1960
+ } | undefined;
1961
+ }[];
1962
+ meta?: Record<string, unknown> | undefined;
1963
+ }, {
1964
+ errors: {
1965
+ status?: string | undefined;
1966
+ code?: string | undefined;
1967
+ id?: string | undefined;
1968
+ links?: {
1969
+ about?: string | undefined;
1970
+ } | undefined;
1971
+ meta?: Record<string, unknown> | undefined;
1972
+ title?: string | undefined;
1973
+ detail?: string | undefined;
1974
+ source?: {
1975
+ pointer?: string | undefined;
1976
+ parameter?: string | undefined;
1977
+ } | undefined;
1978
+ }[];
1979
+ meta?: Record<string, unknown> | undefined;
1980
+ }>;
1981
+ 401: z.ZodObject<{
1982
+ errors: z.ZodArray<z.ZodObject<{
1983
+ id: z.ZodOptional<z.ZodString>;
1984
+ links: z.ZodOptional<z.ZodObject<{
1985
+ about: z.ZodOptional<z.ZodString>;
1986
+ }, "strip", z.ZodTypeAny, {
1987
+ about?: string | undefined;
1988
+ }, {
1989
+ about?: string | undefined;
1990
+ }>>;
1991
+ status: z.ZodOptional<z.ZodString>;
1992
+ code: z.ZodOptional<z.ZodString>;
1993
+ title: z.ZodOptional<z.ZodString>;
1994
+ detail: z.ZodOptional<z.ZodString>;
1995
+ source: z.ZodOptional<z.ZodObject<{
1996
+ pointer: z.ZodOptional<z.ZodString>;
1997
+ parameter: z.ZodOptional<z.ZodString>;
1998
+ }, "strip", z.ZodTypeAny, {
1999
+ pointer?: string | undefined;
2000
+ parameter?: string | undefined;
2001
+ }, {
2002
+ pointer?: string | undefined;
2003
+ parameter?: string | undefined;
2004
+ }>>;
2005
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2006
+ }, "strip", z.ZodTypeAny, {
2007
+ status?: string | undefined;
2008
+ code?: string | undefined;
2009
+ id?: string | undefined;
2010
+ links?: {
2011
+ about?: string | undefined;
2012
+ } | undefined;
2013
+ meta?: Record<string, unknown> | undefined;
2014
+ title?: string | undefined;
2015
+ detail?: string | undefined;
2016
+ source?: {
2017
+ pointer?: string | undefined;
2018
+ parameter?: string | undefined;
2019
+ } | undefined;
2020
+ }, {
2021
+ status?: string | undefined;
2022
+ code?: string | undefined;
2023
+ id?: string | undefined;
2024
+ links?: {
2025
+ about?: string | undefined;
2026
+ } | undefined;
2027
+ meta?: Record<string, unknown> | undefined;
2028
+ title?: string | undefined;
2029
+ detail?: string | undefined;
2030
+ source?: {
2031
+ pointer?: string | undefined;
2032
+ parameter?: string | undefined;
2033
+ } | undefined;
2034
+ }>, "many">;
2035
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2036
+ }, "strip", z.ZodTypeAny, {
2037
+ errors: {
2038
+ status?: string | undefined;
2039
+ code?: string | undefined;
2040
+ id?: string | undefined;
2041
+ links?: {
2042
+ about?: string | undefined;
2043
+ } | undefined;
2044
+ meta?: Record<string, unknown> | undefined;
2045
+ title?: string | undefined;
2046
+ detail?: string | undefined;
2047
+ source?: {
2048
+ pointer?: string | undefined;
2049
+ parameter?: string | undefined;
2050
+ } | undefined;
2051
+ }[];
2052
+ meta?: Record<string, unknown> | undefined;
2053
+ }, {
2054
+ errors: {
2055
+ status?: string | undefined;
2056
+ code?: string | undefined;
2057
+ id?: string | undefined;
2058
+ links?: {
2059
+ about?: string | undefined;
2060
+ } | undefined;
2061
+ meta?: Record<string, unknown> | undefined;
2062
+ title?: string | undefined;
2063
+ detail?: string | undefined;
2064
+ source?: {
2065
+ pointer?: string | undefined;
2066
+ parameter?: string | undefined;
2067
+ } | undefined;
2068
+ }[];
2069
+ meta?: Record<string, unknown> | undefined;
2070
+ }>;
2071
+ 500: z.ZodObject<{
2072
+ errors: z.ZodArray<z.ZodObject<{
2073
+ id: z.ZodOptional<z.ZodString>;
2074
+ links: z.ZodOptional<z.ZodObject<{
2075
+ about: z.ZodOptional<z.ZodString>;
2076
+ }, "strip", z.ZodTypeAny, {
2077
+ about?: string | undefined;
2078
+ }, {
2079
+ about?: string | undefined;
2080
+ }>>;
2081
+ status: z.ZodOptional<z.ZodString>;
2082
+ code: z.ZodOptional<z.ZodString>;
2083
+ title: z.ZodOptional<z.ZodString>;
2084
+ detail: z.ZodOptional<z.ZodString>;
2085
+ source: z.ZodOptional<z.ZodObject<{
2086
+ pointer: z.ZodOptional<z.ZodString>;
2087
+ parameter: z.ZodOptional<z.ZodString>;
2088
+ }, "strip", z.ZodTypeAny, {
2089
+ pointer?: string | undefined;
2090
+ parameter?: string | undefined;
2091
+ }, {
2092
+ pointer?: string | undefined;
2093
+ parameter?: string | undefined;
2094
+ }>>;
2095
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2096
+ }, "strip", z.ZodTypeAny, {
2097
+ status?: string | undefined;
2098
+ code?: string | undefined;
2099
+ id?: string | undefined;
2100
+ links?: {
2101
+ about?: string | undefined;
2102
+ } | undefined;
2103
+ meta?: Record<string, unknown> | undefined;
2104
+ title?: string | undefined;
2105
+ detail?: string | undefined;
2106
+ source?: {
2107
+ pointer?: string | undefined;
2108
+ parameter?: string | undefined;
2109
+ } | undefined;
2110
+ }, {
2111
+ status?: string | undefined;
2112
+ code?: string | undefined;
2113
+ id?: string | undefined;
2114
+ links?: {
2115
+ about?: string | undefined;
2116
+ } | undefined;
2117
+ meta?: Record<string, unknown> | undefined;
2118
+ title?: string | undefined;
2119
+ detail?: string | undefined;
2120
+ source?: {
2121
+ pointer?: string | undefined;
2122
+ parameter?: string | undefined;
2123
+ } | undefined;
2124
+ }>, "many">;
2125
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2126
+ }, "strip", z.ZodTypeAny, {
2127
+ errors: {
2128
+ status?: string | undefined;
2129
+ code?: string | undefined;
2130
+ id?: string | undefined;
2131
+ links?: {
2132
+ about?: string | undefined;
2133
+ } | undefined;
2134
+ meta?: Record<string, unknown> | undefined;
2135
+ title?: string | undefined;
2136
+ detail?: string | undefined;
2137
+ source?: {
2138
+ pointer?: string | undefined;
2139
+ parameter?: string | undefined;
2140
+ } | undefined;
2141
+ }[];
2142
+ meta?: Record<string, unknown> | undefined;
2143
+ }, {
2144
+ errors: {
2145
+ status?: string | undefined;
2146
+ code?: string | undefined;
2147
+ id?: string | undefined;
2148
+ links?: {
2149
+ about?: string | undefined;
2150
+ } | undefined;
2151
+ meta?: Record<string, unknown> | undefined;
2152
+ title?: string | undefined;
2153
+ detail?: string | undefined;
2154
+ source?: {
2155
+ pointer?: string | undefined;
2156
+ parameter?: string | undefined;
2157
+ } | undefined;
2158
+ }[];
2159
+ meta?: Record<string, unknown> | undefined;
2160
+ }>;
2161
+ };
2162
+ };
1540
2163
  };
1541
2164
  //# sourceMappingURL=agents.routes.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"agents.routes.d.ts","sourceRoot":"","sources":["../../src/routes/agents.routes.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoGvB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { initContract } from '@ts-rest/core';
2
2
  import { z } from 'zod';
3
- import { chatRequestSchema, agentChatResponseSchema, conversationHistoryResponseSchema, conversationListResponseSchema, } from '../schemas/agents.schemas';
3
+ import { chatRequestSchema, agentChatResponseSchema, conversationHistoryResponseSchema, conversationListResponseSchema, surveyGeoJsonResponseSchema, } from '../schemas/agents.schemas';
4
4
  import { jsonApiErrorResponseSchema } from '../schemas/common.schemas';
5
5
  const c = initContract();
6
6
  export const agentsRouter = c.router({
@@ -88,4 +88,21 @@ export const agentsRouter = c.router({
88
88
  summary: 'List all conversations for a farm',
89
89
  description: 'Retrieve a list of all conversations for a specific farm, ordered by most recent first',
90
90
  },
91
+ // Generate GeoJSON from survey document
92
+ generateSurveyGeoJSON: {
93
+ method: 'POST',
94
+ path: '/agents/survey/geojson',
95
+ contentType: 'multipart/form-data',
96
+ body: z.object({
97
+ file: z.any(), // File type handled at runtime (File on client, MulterFile on server)
98
+ }),
99
+ responses: {
100
+ 200: surveyGeoJsonResponseSchema,
101
+ 400: jsonApiErrorResponseSchema,
102
+ 401: jsonApiErrorResponseSchema,
103
+ 500: jsonApiErrorResponseSchema,
104
+ },
105
+ summary: 'Generate GeoJSON from survey document',
106
+ description: 'Upload a survey document (PDF or image) and generate standardized GeoJSON. The agent intelligently extracts survey data, handles errors, and makes approximations when needed to create accurate geospatial boundaries.',
107
+ },
91
108
  });