1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202
// =================================================================
//
// * WARNING *
//
// This file is generated!
//
// Changes made to this file will be overwritten. If changes are
// required to the generated code, the service_crategen project
// must be updated to generate the changes.
//
// =================================================================
use std::error::Error;
use std::fmt;
use async_trait::async_trait;
use rusoto_core::credential::ProvideAwsCredentials;
use rusoto_core::region;
use rusoto_core::request::{BufferedHttpResponse, DispatchSignedRequest};
use rusoto_core::{Client, RusotoError};
use rusoto_core::proto;
use rusoto_core::request::HttpResponse;
use rusoto_core::signature::SignedRequest;
#[allow(unused_imports)]
use serde::{Deserialize, Serialize};
impl OrganizationsClient {
fn new_signed_request(&self, http_method: &str, request_uri: &str) -> SignedRequest {
let mut request =
SignedRequest::new(http_method, "organizations", &self.region, request_uri);
request.set_content_type("application/x-amz-json-1.1".to_owned());
request
}
async fn sign_and_dispatch<E>(
&self,
request: SignedRequest,
from_response: fn(BufferedHttpResponse) -> RusotoError<E>,
) -> Result<HttpResponse, RusotoError<E>> {
let mut response = self.client.sign_and_dispatch(request).await?;
if !response.status.is_success() {
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
return Err(from_response(response));
}
Ok(response)
}
}
use serde_json;
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct AcceptHandshakeRequest {
/// <p>The unique identifier (ID) of the handshake that you want to accept.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for handshake ID string requires "h-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "HandshakeId")]
pub handshake_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct AcceptHandshakeResponse {
/// <p>A structure that contains details about the accepted handshake.</p>
#[serde(rename = "Handshake")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshake: Option<Handshake>,
}
/// <p>Contains information about an AWS account that is a member of an organization.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Account {
/// <p>The Amazon Resource Name (ARN) of the account.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p>The email address associated with the AWS account.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for this parameter is a string of characters that represents a standard internet email address.</p>
#[serde(rename = "Email")]
#[serde(skip_serializing_if = "Option::is_none")]
pub email: Option<String>,
/// <p>The unique identifier (ID) of the account.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an account ID string requires exactly 12 digits.</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The method by which the account joined the organization.</p>
#[serde(rename = "JoinedMethod")]
#[serde(skip_serializing_if = "Option::is_none")]
pub joined_method: Option<String>,
/// <p>The date the account became a part of the organization.</p>
#[serde(rename = "JoinedTimestamp")]
#[serde(skip_serializing_if = "Option::is_none")]
pub joined_timestamp: Option<f64>,
/// <p>The friendly name of the account.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
/// <p>The status of the account in the organization.</p>
#[serde(rename = "Status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct AttachPolicyRequest {
/// <p>The unique identifier (ID) of the policy that you want to attach to the target. You can get the ID for the policy by calling the <a>ListPolicies</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a policy ID string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).</p>
#[serde(rename = "PolicyId")]
pub policy_id: String,
/// <p><p>The unique identifier (ID) of the root, OU, or account that you want to attach the policy to. You can get the ID by calling the <a>ListRoots</a>, <a>ListOrganizationalUnitsForParent</a>, or <a>ListAccounts</a> operations.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a target ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Account</b> - A string that consists of exactly 12 digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "TargetId")]
pub target_id: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CancelHandshakeRequest {
/// <p>The unique identifier (ID) of the handshake that you want to cancel. You can get the ID from the <a>ListHandshakesForOrganization</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for handshake ID string requires "h-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "HandshakeId")]
pub handshake_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CancelHandshakeResponse {
/// <p>A structure that contains details about the handshake that you canceled.</p>
#[serde(rename = "Handshake")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshake: Option<Handshake>,
}
/// <p>Contains a list of child entities, either OUs or accounts.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Child {
/// <p><p>The unique identifier (ID) of this child entity.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a child ID string requires one of the following:</p> <ul> <li> <p> <b>Account</b> - A string that consists of exactly 12 digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that contains the OU). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The type of this child entity.</p>
#[serde(rename = "Type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CreateAccountRequest {
/// <p>The friendly name of the member account.</p>
#[serde(rename = "AccountName")]
pub account_name: String,
/// <p>The email address of the owner to assign to the new member account. This email address must not already be associated with another AWS account. You must use a valid email address to complete account creation. You can't access the root user of the account or remove an account that was created with an invalid email address.</p>
#[serde(rename = "Email")]
pub email: String,
/// <p>If set to <code>ALLOW</code>, the new account enables IAM users to access account billing information <i>if</i> they have the required permissions. If set to <code>DENY</code>, only the root user of the new account can access account billing information. For more information, see <a href="https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html#ControllingAccessWebsite-Activate">Activating Access to the Billing and Cost Management Console</a> in the <i>AWS Billing and Cost Management User Guide</i>.</p> <p>If you don't specify this parameter, the value defaults to <code>ALLOW</code>, and IAM users and roles with the required permissions can access billing information for the new account.</p>
#[serde(rename = "IamUserAccessToBilling")]
#[serde(skip_serializing_if = "Option::is_none")]
pub iam_user_access_to_billing: Option<String>,
/// <p>(Optional)</p> <p>The name of an IAM role that AWS Organizations automatically preconfigures in the new member account. This role trusts the management account, allowing users in the management account to assume the role, as permitted by the management account administrator. The role has administrator permissions in the new member account.</p> <p>If you don't specify this parameter, the role name defaults to <code>OrganizationAccountAccessRole</code>.</p> <p>For more information about how to use this role to access the member account, see the following links:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_access.html#orgs_manage_accounts_create-cross-account-role">Accessing and Administering the Member Accounts in Your Organization</a> in the <i>AWS Organizations User Guide</i> </p> </li> <li> <p>Steps 2 and 3 in <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_cross-account-with-roles.html">Tutorial: Delegate Access Across AWS Accounts Using IAM Roles</a> in the <i>IAM User Guide</i> </p> </li> </ul> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter. The pattern can include uppercase letters, lowercase letters, digits with no spaces, and any of the following characters: =,.@-</p>
#[serde(rename = "RoleName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub role_name: Option<String>,
/// <p><p>A list of tags that you want to attach to the newly created account. For each tag in the list, you must specify both a tag key and a value. You can set the value to an empty string, but you can't set it to <code>null</code>. For more information about tagging, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_tagging.html">Tagging AWS Organizations resources</a> in the AWS Organizations User Guide.</p> <note> <p>If any one of the tags is invalid or if you exceed the allowed number of tags for an account, then the entire request fails and the account is not created.</p> </note></p>
#[serde(rename = "Tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreateAccountResponse {
/// <p>A structure that contains details about the request to create an account. This response structure might not be fully populated when you first receive it because account creation is an asynchronous process. You can pass the returned <code>CreateAccountStatus</code> ID as a parameter to <a>DescribeCreateAccountStatus</a> to get status about the progress of the request at later times. You can also check the AWS CloudTrail log for the <code>CreateAccountResult</code> event. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_monitoring.html">Monitoring the Activity in Your Organization</a> in the <i>AWS Organizations User Guide</i>.</p>
#[serde(rename = "CreateAccountStatus")]
#[serde(skip_serializing_if = "Option::is_none")]
pub create_account_status: Option<CreateAccountStatus>,
}
/// <p>Contains the status about a <a>CreateAccount</a> or <a>CreateGovCloudAccount</a> request to create an AWS account or an AWS GovCloud (US) account in an organization.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreateAccountStatus {
/// <p>If the account was created successfully, the unique identifier (ID) of the new account.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an account ID string requires exactly 12 digits.</p>
#[serde(rename = "AccountId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub account_id: Option<String>,
/// <p>The account name given to the account when it was created.</p>
#[serde(rename = "AccountName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub account_name: Option<String>,
/// <p>The date and time that the account was created and the request completed.</p>
#[serde(rename = "CompletedTimestamp")]
#[serde(skip_serializing_if = "Option::is_none")]
pub completed_timestamp: Option<f64>,
/// <p><p>If the request failed, a description of the reason for the failure.</p> <ul> <li> <p>ACCOUNT<em>LIMIT</em>EXCEEDED: The account couldn't be created because you reached the limit on the number of accounts in your organization.</p> </li> <li> <p>CONCURRENT<em>ACCOUNT</em>MODIFICATION: You already submitted a request with the same information.</p> </li> <li> <p>EMAIL<em>ALREADY</em>EXISTS: The account could not be created because another AWS account with that email address already exists.</p> </li> <li> <p>FAILED<em>BUSINESS</em>VALIDATION: The AWS account that owns your organization failed to receive business license validation.</p> </li> <li> <p>GOVCLOUD<em>ACCOUNT</em>ALREADY<em>EXISTS: The account in the AWS GovCloud (US) Region could not be created because this Region already includes an account with that email address.</p> </li> <li> <p>IDENTITY</em>INVALID<em>BUSINESS</em>VALIDATION: The AWS account that owns your organization can't complete business license validation because it doesn't have valid identity data.</p> </li> <li> <p>INVALID<em>ADDRESS: The account could not be created because the address you provided is not valid.</p> </li> <li> <p>INVALID</em>EMAIL: The account could not be created because the email address you provided is not valid.</p> </li> <li> <p>INTERNAL<em>FAILURE: The account could not be created because of an internal failure. Try again later. If the problem persists, contact AWS Customer Support.</p> </li> <li> <p>MISSING</em>BUSINESS<em>VALIDATION: The AWS account that owns your organization has not received Business Validation.</p> </li> <li> <p> MISSING</em>PAYMENT<em>INSTRUMENT: You must configure the management account with a valid payment method, such as a credit card.</p> </li> <li> <p>PENDING</em>BUSINESS<em>VALIDATION: The AWS account that owns your organization is still in the process of completing business license validation.</p> </li> <li> <p>UNKNOWN</em>BUSINESS_VALIDATION: The AWS account that owns your organization has an unknown issue with business license validation.</p> </li> </ul></p>
#[serde(rename = "FailureReason")]
#[serde(skip_serializing_if = "Option::is_none")]
pub failure_reason: Option<String>,
/// <p>If the account was created successfully, the unique identifier (ID) of the new account in the AWS GovCloud (US) Region.</p>
#[serde(rename = "GovCloudAccountId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub gov_cloud_account_id: Option<String>,
/// <p>The unique identifier (ID) that references this request. You get this value from the response of the initial <a>CreateAccount</a> request to create the account.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a create account request ID string requires "car-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The date and time that the request was made for the account creation.</p>
#[serde(rename = "RequestedTimestamp")]
#[serde(skip_serializing_if = "Option::is_none")]
pub requested_timestamp: Option<f64>,
/// <p>The status of the asynchronous request to create an AWS account.</p>
#[serde(rename = "State")]
#[serde(skip_serializing_if = "Option::is_none")]
pub state: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CreateGovCloudAccountRequest {
/// <p>The friendly name of the member account.</p>
#[serde(rename = "AccountName")]
pub account_name: String,
/// <p>The email address of the owner to assign to the new member account in the commercial Region. This email address must not already be associated with another AWS account. You must use a valid email address to complete account creation. You can't access the root user of the account or remove an account that was created with an invalid email address. Like all request parameters for <code>CreateGovCloudAccount</code>, the request for the email address for the AWS GovCloud (US) account originates from the commercial Region, not from the AWS GovCloud (US) Region.</p>
#[serde(rename = "Email")]
pub email: String,
/// <p>If set to <code>ALLOW</code>, the new linked account in the commercial Region enables IAM users to access account billing information <i>if</i> they have the required permissions. If set to <code>DENY</code>, only the root user of the new account can access account billing information. For more information, see <a href="https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html#ControllingAccessWebsite-Activate">Activating Access to the Billing and Cost Management Console</a> in the <i>AWS Billing and Cost Management User Guide.</i> </p> <p>If you don't specify this parameter, the value defaults to <code>ALLOW</code>, and IAM users and roles with the required permissions can access billing information for the new account.</p>
#[serde(rename = "IamUserAccessToBilling")]
#[serde(skip_serializing_if = "Option::is_none")]
pub iam_user_access_to_billing: Option<String>,
/// <p>(Optional)</p> <p>The name of an IAM role that AWS Organizations automatically preconfigures in the new member accounts in both the AWS GovCloud (US) Region and in the commercial Region. This role trusts the management account, allowing users in the management account to assume the role, as permitted by the management account administrator. The role has administrator permissions in the new member account.</p> <p>If you don't specify this parameter, the role name defaults to <code>OrganizationAccountAccessRole</code>.</p> <p>For more information about how to use this role to access the member account, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_access.html#orgs_manage_accounts_create-cross-account-role">Accessing and Administering the Member Accounts in Your Organization</a> in the <i>AWS Organizations User Guide</i> and steps 2 and 3 in <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_cross-account-with-roles.html">Tutorial: Delegate Access Across AWS Accounts Using IAM Roles</a> in the <i>IAM User Guide.</i> </p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter. The pattern can include uppercase letters, lowercase letters, digits with no spaces, and any of the following characters: =,.@-</p>
#[serde(rename = "RoleName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub role_name: Option<String>,
/// <p><p>A list of tags that you want to attach to the newly created account. These tags are attached to the commercial account associated with the GovCloud account, and not to the GovCloud account itself. To add tags to the actual GovCloud account, call the <a>TagResource</a> operation in the GovCloud region after the new GovCloud account exists.</p> <p>For each tag in the list, you must specify both a tag key and a value. You can set the value to an empty string, but you can't set it to <code>null</code>. For more information about tagging, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_tagging.html">Tagging AWS Organizations resources</a> in the AWS Organizations User Guide.</p> <note> <p>If any one of the tags is invalid or if you exceed the allowed number of tags for an account, then the entire request fails and the account is not created.</p> </note></p>
#[serde(rename = "Tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreateGovCloudAccountResponse {
#[serde(rename = "CreateAccountStatus")]
#[serde(skip_serializing_if = "Option::is_none")]
pub create_account_status: Option<CreateAccountStatus>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CreateOrganizationRequest {
/// <p><p>Specifies the feature set supported by the new organization. Each feature set supports different levels of functionality.</p> <ul> <li> <p> <code>CONSOLIDATED<em>BILLING</code>: All member accounts have their bills consolidated to and paid by the management account. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>getting-started<em>concepts.html#feature-set-cb-only">Consolidated billing</a> in the <i>AWS Organizations User Guide.</i> </p> <p> The consolidated billing feature subset isn't available for organizations in the AWS GovCloud (US) Region.</p> </li> <li> <p> <code>ALL</code>: In addition to all the features supported by the consolidated billing feature set, the management account can also apply any policy type to any member account in the organization. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>getting-started_concepts.html#feature-set-all">All features</a> in the <i>AWS Organizations User Guide.</i> </p> </li> </ul></p>
#[serde(rename = "FeatureSet")]
#[serde(skip_serializing_if = "Option::is_none")]
pub feature_set: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreateOrganizationResponse {
/// <p>A structure that contains details about the newly created organization.</p>
#[serde(rename = "Organization")]
#[serde(skip_serializing_if = "Option::is_none")]
pub organization: Option<Organization>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CreateOrganizationalUnitRequest {
/// <p>The friendly name to assign to the new OU.</p>
#[serde(rename = "Name")]
pub name: String,
/// <p><p>The unique identifier (ID) of the parent root or OU that you want to create the new OU in.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a parent ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "ParentId")]
pub parent_id: String,
/// <p><p>A list of tags that you want to attach to the newly created OU. For each tag in the list, you must specify both a tag key and a value. You can set the value to an empty string, but you can't set it to <code>null</code>. For more information about tagging, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_tagging.html">Tagging AWS Organizations resources</a> in the AWS Organizations User Guide.</p> <note> <p>If any one of the tags is invalid or if you exceed the allowed number of tags for an OU, then the entire request fails and the OU is not created.</p> </note></p>
#[serde(rename = "Tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreateOrganizationalUnitResponse {
/// <p>A structure that contains details about the newly created OU.</p>
#[serde(rename = "OrganizationalUnit")]
#[serde(skip_serializing_if = "Option::is_none")]
pub organizational_unit: Option<OrganizationalUnit>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CreatePolicyRequest {
/// <p>The policy text content to add to the new policy. The text that you supply must adhere to the rules of the policy type you specify in the <code>Type</code> parameter.</p>
#[serde(rename = "Content")]
pub content: String,
/// <p>An optional description to assign to the policy.</p>
#[serde(rename = "Description")]
pub description: String,
/// <p>The friendly name to assign to the policy.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
pub name: String,
/// <p><p>A list of tags that you want to attach to the newly created policy. For each tag in the list, you must specify both a tag key and a value. You can set the value to an empty string, but you can't set it to <code>null</code>. For more information about tagging, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_tagging.html">Tagging AWS Organizations resources</a> in the AWS Organizations User Guide.</p> <note> <p>If any one of the tags is invalid or if you exceed the allowed number of tags for a policy, then the entire request fails and the policy is not created.</p> </note></p>
#[serde(rename = "Tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
/// <p><p>The type of policy to create. You can specify one of the following values:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES<em>OPT</em>OUT<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>backup.html">BACKUP<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>scp.html">SERVICE<em>CONTROL</em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_tag-policies.html">TAG_POLICY</a> </p> </li> </ul></p>
#[serde(rename = "Type")]
pub type_: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreatePolicyResponse {
/// <p>A structure that contains details about the newly created policy.</p>
#[serde(rename = "Policy")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policy: Option<Policy>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeclineHandshakeRequest {
/// <p>The unique identifier (ID) of the handshake that you want to decline. You can get the ID from the <a>ListHandshakesForAccount</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for handshake ID string requires "h-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "HandshakeId")]
pub handshake_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DeclineHandshakeResponse {
/// <p>A structure that contains details about the declined handshake. The state is updated to show the value <code>DECLINED</code>.</p>
#[serde(rename = "Handshake")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshake: Option<Handshake>,
}
/// <p>Contains information about the delegated administrator.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DelegatedAdministrator {
/// <p>The Amazon Resource Name (ARN) of the delegated administrator's account.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p>The date when the account was made a delegated administrator.</p>
#[serde(rename = "DelegationEnabledDate")]
#[serde(skip_serializing_if = "Option::is_none")]
pub delegation_enabled_date: Option<f64>,
/// <p>The email address that is associated with the delegated administrator's AWS account.</p>
#[serde(rename = "Email")]
#[serde(skip_serializing_if = "Option::is_none")]
pub email: Option<String>,
/// <p>The unique identifier (ID) of the delegated administrator's account.</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The method by which the delegated administrator's account joined the organization.</p>
#[serde(rename = "JoinedMethod")]
#[serde(skip_serializing_if = "Option::is_none")]
pub joined_method: Option<String>,
/// <p>The date when the delegated administrator's account became a part of the organization.</p>
#[serde(rename = "JoinedTimestamp")]
#[serde(skip_serializing_if = "Option::is_none")]
pub joined_timestamp: Option<f64>,
/// <p>The friendly name of the delegated administrator's account.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
/// <p>The status of the delegated administrator's account in the organization.</p>
#[serde(rename = "Status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
}
/// <p>Contains information about the AWS service for which the account is a delegated administrator.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DelegatedService {
/// <p>The date that the account became a delegated administrator for this service. </p>
#[serde(rename = "DelegationEnabledDate")]
#[serde(skip_serializing_if = "Option::is_none")]
pub delegation_enabled_date: Option<f64>,
/// <p>The name of an AWS service that can request an operation for the specified service. This is typically in the form of a URL, such as: <code> <i>servicename</i>.amazonaws.com</code>.</p>
#[serde(rename = "ServicePrincipal")]
#[serde(skip_serializing_if = "Option::is_none")]
pub service_principal: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeleteOrganizationalUnitRequest {
/// <p>The unique identifier (ID) of the organizational unit that you want to delete. You can get the ID from the <a>ListOrganizationalUnitsForParent</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an organizational unit ID string requires "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that contains the OU). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p>
#[serde(rename = "OrganizationalUnitId")]
pub organizational_unit_id: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeletePolicyRequest {
/// <p>The unique identifier (ID) of the policy that you want to delete. You can get the ID from the <a>ListPolicies</a> or <a>ListPoliciesForTarget</a> operations.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a policy ID string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).</p>
#[serde(rename = "PolicyId")]
pub policy_id: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeregisterDelegatedAdministratorRequest {
/// <p>The account ID number of the member account in the organization that you want to deregister as a delegated administrator.</p>
#[serde(rename = "AccountId")]
pub account_id: String,
/// <p>The service principal name of an AWS service for which the account is a delegated administrator.</p> <p>Delegated administrator privileges are revoked for only the specified AWS service from the member account. If the specified service is the only service for which the member account is a delegated administrator, the operation also revokes Organizations read action permissions.</p>
#[serde(rename = "ServicePrincipal")]
pub service_principal: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DescribeAccountRequest {
/// <p>The unique identifier (ID) of the AWS account that you want information about. You can get the ID from the <a>ListAccounts</a> or <a>ListAccountsForParent</a> operations.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an account ID string requires exactly 12 digits.</p>
#[serde(rename = "AccountId")]
pub account_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DescribeAccountResponse {
/// <p>A structure that contains information about the requested account.</p>
#[serde(rename = "Account")]
#[serde(skip_serializing_if = "Option::is_none")]
pub account: Option<Account>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DescribeCreateAccountStatusRequest {
/// <p>Specifies the <code>Id</code> value that uniquely identifies the <code>CreateAccount</code> request. You can get the value from the <code>CreateAccountStatus.Id</code> response in an earlier <a>CreateAccount</a> request, or from the <a>ListCreateAccountStatus</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a create account request ID string requires "car-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "CreateAccountRequestId")]
pub create_account_request_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DescribeCreateAccountStatusResponse {
/// <p>A structure that contains the current status of an account creation request.</p>
#[serde(rename = "CreateAccountStatus")]
#[serde(skip_serializing_if = "Option::is_none")]
pub create_account_status: Option<CreateAccountStatus>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DescribeEffectivePolicyRequest {
/// <p><p>The type of policy that you want information about. You can specify one of the following values:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES<em>OPT</em>OUT<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>backup.html">BACKUP<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>tag-policies.html">TAG_POLICY</a> </p> </li> </ul></p>
#[serde(rename = "PolicyType")]
pub policy_type: String,
/// <p>When you're signed in as the management account, specify the ID of the account that you want details about. Specifying an organization root or organizational unit (OU) as the target is not supported.</p>
#[serde(rename = "TargetId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub target_id: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DescribeEffectivePolicyResponse {
/// <p>The contents of the effective policy.</p>
#[serde(rename = "EffectivePolicy")]
#[serde(skip_serializing_if = "Option::is_none")]
pub effective_policy: Option<EffectivePolicy>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DescribeHandshakeRequest {
/// <p>The unique identifier (ID) of the handshake that you want information about. You can get the ID from the original call to <a>InviteAccountToOrganization</a>, or from a call to <a>ListHandshakesForAccount</a> or <a>ListHandshakesForOrganization</a>.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for handshake ID string requires "h-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "HandshakeId")]
pub handshake_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DescribeHandshakeResponse {
/// <p>A structure that contains information about the specified handshake.</p>
#[serde(rename = "Handshake")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshake: Option<Handshake>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DescribeOrganizationResponse {
/// <p><p>A structure that contains information about the organization.</p> <important> <p>The <code>AvailablePolicyTypes</code> part of the response is deprecated, and you shouldn't use it in your apps. It doesn't include any policy type supported by Organizations other than SCPs. To determine which policy types are enabled in your organization, use the <code> <a>ListRoots</a> </code> operation.</p> </important></p>
#[serde(rename = "Organization")]
#[serde(skip_serializing_if = "Option::is_none")]
pub organization: Option<Organization>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DescribeOrganizationalUnitRequest {
/// <p>The unique identifier (ID) of the organizational unit that you want details about. You can get the ID from the <a>ListOrganizationalUnitsForParent</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an organizational unit ID string requires "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that contains the OU). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p>
#[serde(rename = "OrganizationalUnitId")]
pub organizational_unit_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DescribeOrganizationalUnitResponse {
/// <p>A structure that contains details about the specified OU.</p>
#[serde(rename = "OrganizationalUnit")]
#[serde(skip_serializing_if = "Option::is_none")]
pub organizational_unit: Option<OrganizationalUnit>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DescribePolicyRequest {
/// <p>The unique identifier (ID) of the policy that you want details about. You can get the ID from the <a>ListPolicies</a> or <a>ListPoliciesForTarget</a> operations.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a policy ID string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).</p>
#[serde(rename = "PolicyId")]
pub policy_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DescribePolicyResponse {
/// <p>A structure that contains details about the specified policy.</p>
#[serde(rename = "Policy")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policy: Option<Policy>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DetachPolicyRequest {
/// <p>The unique identifier (ID) of the policy you want to detach. You can get the ID from the <a>ListPolicies</a> or <a>ListPoliciesForTarget</a> operations.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a policy ID string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).</p>
#[serde(rename = "PolicyId")]
pub policy_id: String,
/// <p><p>The unique identifier (ID) of the root, OU, or account that you want to detach the policy from. You can get the ID from the <a>ListRoots</a>, <a>ListOrganizationalUnitsForParent</a>, or <a>ListAccounts</a> operations.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a target ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Account</b> - A string that consists of exactly 12 digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "TargetId")]
pub target_id: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DisableAWSServiceAccessRequest {
/// <p>The service principal name of the AWS service for which you want to disable integration with your organization. This is typically in the form of a URL, such as <code> <i>service-abbreviation</i>.amazonaws.com</code>.</p>
#[serde(rename = "ServicePrincipal")]
pub service_principal: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DisablePolicyTypeRequest {
/// <p><p>The policy type that you want to disable in this root. You can specify one of the following values:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES<em>OPT</em>OUT<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>backup.html">BACKUP<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>scp.html">SERVICE<em>CONTROL</em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_tag-policies.html">TAG_POLICY</a> </p> </li> </ul></p>
#[serde(rename = "PolicyType")]
pub policy_type: String,
/// <p>The unique identifier (ID) of the root in which you want to disable a policy type. You can get the ID from the <a>ListRoots</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a root ID string requires "r-" followed by from 4 to 32 lowercase letters or digits.</p>
#[serde(rename = "RootId")]
pub root_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DisablePolicyTypeResponse {
/// <p>A structure that shows the root with the updated list of enabled policy types.</p>
#[serde(rename = "Root")]
#[serde(skip_serializing_if = "Option::is_none")]
pub root: Option<Root>,
}
/// <p>Contains rules to be applied to the affected accounts. The effective policy is the aggregation of any policies the account inherits, plus any policy directly attached to the account.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct EffectivePolicy {
/// <p>The time of the last update to this policy.</p>
#[serde(rename = "LastUpdatedTimestamp")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_updated_timestamp: Option<f64>,
/// <p>The text content of the policy.</p>
#[serde(rename = "PolicyContent")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policy_content: Option<String>,
/// <p>The policy type.</p>
#[serde(rename = "PolicyType")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policy_type: Option<String>,
/// <p>The account ID of the policy target. </p>
#[serde(rename = "TargetId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub target_id: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct EnableAWSServiceAccessRequest {
/// <p>The service principal name of the AWS service for which you want to enable integration with your organization. This is typically in the form of a URL, such as <code> <i>service-abbreviation</i>.amazonaws.com</code>.</p>
#[serde(rename = "ServicePrincipal")]
pub service_principal: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct EnableAllFeaturesRequest {}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct EnableAllFeaturesResponse {
/// <p>A structure that contains details about the handshake created to support this request to enable all features in the organization.</p>
#[serde(rename = "Handshake")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshake: Option<Handshake>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct EnablePolicyTypeRequest {
/// <p><p>The policy type that you want to enable. You can specify one of the following values:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES<em>OPT</em>OUT<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>backup.html">BACKUP<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>scp.html">SERVICE<em>CONTROL</em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_tag-policies.html">TAG_POLICY</a> </p> </li> </ul></p>
#[serde(rename = "PolicyType")]
pub policy_type: String,
/// <p>The unique identifier (ID) of the root in which you want to enable a policy type. You can get the ID from the <a>ListRoots</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a root ID string requires "r-" followed by from 4 to 32 lowercase letters or digits.</p>
#[serde(rename = "RootId")]
pub root_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct EnablePolicyTypeResponse {
/// <p>A structure that shows the root with the updated list of enabled policy types.</p>
#[serde(rename = "Root")]
#[serde(skip_serializing_if = "Option::is_none")]
pub root: Option<Root>,
}
/// <p>A structure that contains details of a service principal that represents an AWS service that is enabled to integrate with AWS Organizations.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct EnabledServicePrincipal {
/// <p>The date that the service principal was enabled for integration with AWS Organizations.</p>
#[serde(rename = "DateEnabled")]
#[serde(skip_serializing_if = "Option::is_none")]
pub date_enabled: Option<f64>,
/// <p>The name of the service principal. This is typically in the form of a URL, such as: <code> <i>servicename</i>.amazonaws.com</code>.</p>
#[serde(rename = "ServicePrincipal")]
#[serde(skip_serializing_if = "Option::is_none")]
pub service_principal: Option<String>,
}
/// <p>Contains information that must be exchanged to securely establish a relationship between two accounts (an <i>originator</i> and a <i>recipient</i>). For example, when a management account (the originator) invites another account (the recipient) to join its organization, the two accounts exchange information as a series of handshake requests and responses.</p> <p> <b>Note:</b> Handshakes that are <code>CANCELED</code>, <code>ACCEPTED</code>, or <code>DECLINED</code> show up in lists for only 30 days after entering that state After that they are deleted.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Handshake {
/// <p><p>The type of handshake, indicating what action occurs when the recipient accepts the handshake. The following handshake types are supported:</p> <ul> <li> <p> <b>INVITE</b>: This type of handshake represents a request to join an organization. It is always sent from the management account to only non-member accounts.</p> </li> <li> <p> <b>ENABLE<em>ALL</em>FEATURES</b>: This type of handshake represents a request to enable all features in an organization. It is always sent from the management account to only <i>invited</i> member accounts. Created accounts do not receive this because those accounts were created by the organization's management account and approval is inferred.</p> </li> <li> <p> <b>APPROVE<em>ALL</em>FEATURES</b>: This type of handshake is sent from the Organizations service when all member accounts have approved the <code>ENABLE<em>ALL</em>FEATURES</code> invitation. It is sent only to the management account and signals the master that it can finalize the process to enable all features.</p> </li> </ul></p>
#[serde(rename = "Action")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action: Option<String>,
/// <p>The Amazon Resource Name (ARN) of a handshake.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p>The date and time that the handshake expires. If the recipient of the handshake request fails to respond before the specified date and time, the handshake becomes inactive and is no longer valid.</p>
#[serde(rename = "ExpirationTimestamp")]
#[serde(skip_serializing_if = "Option::is_none")]
pub expiration_timestamp: Option<f64>,
/// <p>The unique identifier (ID) of a handshake. The originating account creates the ID when it initiates the handshake.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for handshake ID string requires "h-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>Information about the two accounts that are participating in the handshake.</p>
#[serde(rename = "Parties")]
#[serde(skip_serializing_if = "Option::is_none")]
pub parties: Option<Vec<HandshakeParty>>,
/// <p>The date and time that the handshake request was made.</p>
#[serde(rename = "RequestedTimestamp")]
#[serde(skip_serializing_if = "Option::is_none")]
pub requested_timestamp: Option<f64>,
/// <p>Additional information that is needed to process the handshake.</p>
#[serde(rename = "Resources")]
#[serde(skip_serializing_if = "Option::is_none")]
pub resources: Option<Vec<HandshakeResource>>,
/// <p><p>The current state of the handshake. Use the state to trace the flow of the handshake through the process from its creation to its acceptance. The meaning of each of the valid values is as follows:</p> <ul> <li> <p> <b>REQUESTED</b>: This handshake was sent to multiple recipients (applicable to only some handshake types) and not all recipients have responded yet. The request stays in this state until all recipients respond.</p> </li> <li> <p> <b>OPEN</b>: This handshake was sent to multiple recipients (applicable to only some policy types) and all recipients have responded, allowing the originator to complete the handshake action.</p> </li> <li> <p> <b>CANCELED</b>: This handshake is no longer active because it was canceled by the originating account.</p> </li> <li> <p> <b>ACCEPTED</b>: This handshake is complete because it has been accepted by the recipient.</p> </li> <li> <p> <b>DECLINED</b>: This handshake is no longer active because it was declined by the recipient account.</p> </li> <li> <p> <b>EXPIRED</b>: This handshake is no longer active because the originator did not receive a response of any kind from the recipient before the expiration time (15 days).</p> </li> </ul></p>
#[serde(rename = "State")]
#[serde(skip_serializing_if = "Option::is_none")]
pub state: Option<String>,
}
/// <p>Specifies the criteria that are used to select the handshakes for the operation.</p>
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct HandshakeFilter {
/// <p>Specifies the type of handshake action.</p> <p>If you specify <code>ActionType</code>, you cannot also specify <code>ParentHandshakeId</code>.</p>
#[serde(rename = "ActionType")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_type: Option<String>,
/// <p>Specifies the parent handshake. Only used for handshake types that are a child of another type.</p> <p>If you specify <code>ParentHandshakeId</code>, you cannot also specify <code>ActionType</code>.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for handshake ID string requires "h-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "ParentHandshakeId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub parent_handshake_id: Option<String>,
}
/// <p>Identifies a participant in a handshake.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct HandshakeParty {
/// <p>The unique identifier (ID) for the party.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for handshake ID string requires "h-" followed by from 8 to 32 lowercase letters or digits.</p>
#[serde(rename = "Id")]
pub id: String,
/// <p>The type of party.</p>
#[serde(rename = "Type")]
pub type_: String,
}
/// <p>Contains additional data that is needed to process a handshake.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct HandshakeResource {
/// <p>When needed, contains an additional array of <code>HandshakeResource</code> objects.</p>
#[serde(rename = "Resources")]
#[serde(skip_serializing_if = "Option::is_none")]
pub resources: Option<Vec<HandshakeResource>>,
/// <p><p>The type of information being passed, specifying how the value is to be interpreted by the other party:</p> <ul> <li> <p> <code>ACCOUNT</code> - Specifies an AWS account ID number.</p> </li> <li> <p> <code>ORGANIZATION</code> - Specifies an organization ID number.</p> </li> <li> <p> <code>EMAIL</code> - Specifies the email address that is associated with the account that receives the handshake. </p> </li> <li> <p> <code>OWNER<em>EMAIL</code> - Specifies the email address associated with the management account. Included as information about an organization. </p> </li> <li> <p> <code>OWNER</em>NAME</code> - Specifies the name associated with the management account. Included as information about an organization. </p> </li> <li> <p> <code>NOTES</code> - Additional text provided by the handshake initiator and intended for the recipient to read.</p> </li> </ul></p>
#[serde(rename = "Type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
/// <p>The information that is passed to the other party in the handshake. The format of the value string must match the requirements of the specified type.</p>
#[serde(rename = "Value")]
#[serde(skip_serializing_if = "Option::is_none")]
pub value: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct InviteAccountToOrganizationRequest {
/// <p>Additional information that you want to include in the generated email to the recipient account owner.</p>
#[serde(rename = "Notes")]
#[serde(skip_serializing_if = "Option::is_none")]
pub notes: Option<String>,
/// <p><p>A list of tags that you want to attach to the account when it becomes a member of the organization. For each tag in the list, you must specify both a tag key and a value. You can set the value to an empty string, but you can't set it to <code>null</code>. For more information about tagging, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_tagging.html">Tagging AWS Organizations resources</a> in the AWS Organizations User Guide.</p> <important> <p>Any tags in the request are checked for compliance with any applicable tag policies when the request is made. The request is rejected if the tags in the request don't match the requirements of the policy at that time. Tag policy compliance is <i> <b>not</b> </i> checked again when the invitation is accepted and the tags are actually attached to the account. That means that if the tag policy changes between the invitation and the acceptance, then that tags could potentially be non-compliant.</p> </important> <note> <p>If any one of the tags is invalid or if you exceed the allowed number of tags for an account, then the entire request fails and invitations are not sent.</p> </note></p>
#[serde(rename = "Tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
/// <p>The identifier (ID) of the AWS account that you want to invite to join your organization. This is a JSON object that contains the following elements:</p> <p> <code>{ "Type": "ACCOUNT", "Id": "<<i> <b>account id number</b> </i>>" }</code> </p> <p>If you use the AWS CLI, you can submit this as a single string, similar to the following example:</p> <p> <code>--target Id=123456789012,Type=ACCOUNT</code> </p> <p>If you specify <code>"Type": "ACCOUNT"</code>, you must provide the AWS account ID number as the <code>Id</code>. If you specify <code>"Type": "EMAIL"</code>, you must specify the email address that is associated with the account.</p> <p> <code>--target Id=diego@example.com,Type=EMAIL</code> </p>
#[serde(rename = "Target")]
pub target: HandshakeParty,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct InviteAccountToOrganizationResponse {
/// <p>A structure that contains details about the handshake that is created to support this invitation request.</p>
#[serde(rename = "Handshake")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshake: Option<Handshake>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListAWSServiceAccessForOrganizationRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListAWSServiceAccessForOrganizationResponse {
/// <p>A list of the service principals for the services that are enabled to integrate with your organization. Each principal is a structure that includes the name and the date that it was enabled for integration with AWS Organizations.</p>
#[serde(rename = "EnabledServicePrincipals")]
#[serde(skip_serializing_if = "Option::is_none")]
pub enabled_service_principals: Option<Vec<EnabledServicePrincipal>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListAccountsForParentRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>The unique identifier (ID) for the parent root or organization unit (OU) whose accounts you want to list.</p>
#[serde(rename = "ParentId")]
pub parent_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListAccountsForParentResponse {
/// <p>A list of the accounts in the specified root or OU.</p>
#[serde(rename = "Accounts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub accounts: Option<Vec<Account>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListAccountsRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListAccountsResponse {
/// <p>A list of objects in the organization.</p>
#[serde(rename = "Accounts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub accounts: Option<Vec<Account>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListChildrenRequest {
/// <p>Filters the output to include only the specified child type.</p>
#[serde(rename = "ChildType")]
pub child_type: String,
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p><p>The unique identifier (ID) for the parent root or OU whose children you want to list.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a parent ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "ParentId")]
pub parent_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListChildrenResponse {
/// <p>The list of children of the specified parent container.</p>
#[serde(rename = "Children")]
#[serde(skip_serializing_if = "Option::is_none")]
pub children: Option<Vec<Child>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListCreateAccountStatusRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>A list of one or more states that you want included in the response. If this parameter isn't present, all requests are included in the response.</p>
#[serde(rename = "States")]
#[serde(skip_serializing_if = "Option::is_none")]
pub states: Option<Vec<String>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListCreateAccountStatusResponse {
/// <p>A list of objects with details about the requests. Certain elements, such as the accountId number, are present in the output only after the account has been successfully created.</p>
#[serde(rename = "CreateAccountStatuses")]
#[serde(skip_serializing_if = "Option::is_none")]
pub create_account_statuses: Option<Vec<CreateAccountStatus>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListDelegatedAdministratorsRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>Specifies a service principal name. If specified, then the operation lists the delegated administrators only for the specified service.</p> <p>If you don't specify a service principal, the operation lists all delegated administrators for all services in your organization.</p>
#[serde(rename = "ServicePrincipal")]
#[serde(skip_serializing_if = "Option::is_none")]
pub service_principal: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListDelegatedAdministratorsResponse {
/// <p>The list of delegated administrators in your organization.</p>
#[serde(rename = "DelegatedAdministrators")]
#[serde(skip_serializing_if = "Option::is_none")]
pub delegated_administrators: Option<Vec<DelegatedAdministrator>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListDelegatedServicesForAccountRequest {
/// <p>The account ID number of a delegated administrator account in the organization.</p>
#[serde(rename = "AccountId")]
pub account_id: String,
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListDelegatedServicesForAccountResponse {
/// <p>The services for which the account is a delegated administrator.</p>
#[serde(rename = "DelegatedServices")]
#[serde(skip_serializing_if = "Option::is_none")]
pub delegated_services: Option<Vec<DelegatedService>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListHandshakesForAccountRequest {
/// <p>Filters the handshakes that you want included in the response. The default is all types. Use the <code>ActionType</code> element to limit the output to only a specified type, such as <code>INVITE</code>, <code>ENABLE_ALL_FEATURES</code>, or <code>APPROVE_ALL_FEATURES</code>. Alternatively, for the <code>ENABLE_ALL_FEATURES</code> handshake that generates a separate child handshake for each member account, you can specify <code>ParentHandshakeId</code> to see only the handshakes that were generated by that parent request.</p>
#[serde(rename = "Filter")]
#[serde(skip_serializing_if = "Option::is_none")]
pub filter: Option<HandshakeFilter>,
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListHandshakesForAccountResponse {
/// <p>A list of <a>Handshake</a> objects with details about each of the handshakes that is associated with the specified account.</p>
#[serde(rename = "Handshakes")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshakes: Option<Vec<Handshake>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListHandshakesForOrganizationRequest {
/// <p>A filter of the handshakes that you want included in the response. The default is all types. Use the <code>ActionType</code> element to limit the output to only a specified type, such as <code>INVITE</code>, <code>ENABLE-ALL-FEATURES</code>, or <code>APPROVE-ALL-FEATURES</code>. Alternatively, for the <code>ENABLE-ALL-FEATURES</code> handshake that generates a separate child handshake for each member account, you can specify the <code>ParentHandshakeId</code> to see only the handshakes that were generated by that parent request.</p>
#[serde(rename = "Filter")]
#[serde(skip_serializing_if = "Option::is_none")]
pub filter: Option<HandshakeFilter>,
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListHandshakesForOrganizationResponse {
/// <p>A list of <a>Handshake</a> objects with details about each of the handshakes that are associated with an organization.</p>
#[serde(rename = "Handshakes")]
#[serde(skip_serializing_if = "Option::is_none")]
pub handshakes: Option<Vec<Handshake>>,
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListOrganizationalUnitsForParentRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p><p>The unique identifier (ID) of the root or OU whose child OUs you want to list.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a parent ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "ParentId")]
pub parent_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListOrganizationalUnitsForParentResponse {
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>A list of the OUs in the specified root or parent OU.</p>
#[serde(rename = "OrganizationalUnits")]
#[serde(skip_serializing_if = "Option::is_none")]
pub organizational_units: Option<Vec<OrganizationalUnit>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListParentsRequest {
/// <p><p>The unique identifier (ID) of the OU or account whose parent containers you want to list. Don't specify a root.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a child ID string requires one of the following:</p> <ul> <li> <p> <b>Account</b> - A string that consists of exactly 12 digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that contains the OU). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "ChildId")]
pub child_id: String,
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListParentsResponse {
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>A list of parents for the specified child account or OU.</p>
#[serde(rename = "Parents")]
#[serde(skip_serializing_if = "Option::is_none")]
pub parents: Option<Vec<Parent>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListPoliciesForTargetRequest {
/// <p><p>The type of policy that you want to include in the returned list. You must specify one of the following values:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES<em>OPT</em>OUT<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>backup.html">BACKUP<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>scp.html">SERVICE<em>CONTROL</em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_tag-policies.html">TAG_POLICY</a> </p> </li> </ul></p>
#[serde(rename = "Filter")]
pub filter: String,
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p><p>The unique identifier (ID) of the root, organizational unit, or account whose policies you want to list.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a target ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Account</b> - A string that consists of exactly 12 digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "TargetId")]
pub target_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListPoliciesForTargetResponse {
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>The list of policies that match the criteria in the request.</p>
#[serde(rename = "Policies")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policies: Option<Vec<PolicySummary>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListPoliciesRequest {
/// <p><p>Specifies the type of policy that you want to include in the response. You must specify one of the following values:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES<em>OPT</em>OUT<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>backup.html">BACKUP<em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>policies</em>scp.html">SERVICE<em>CONTROL</em>POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_tag-policies.html">TAG_POLICY</a> </p> </li> </ul></p>
#[serde(rename = "Filter")]
pub filter: String,
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListPoliciesResponse {
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>A list of policies that match the filter criteria in the request. The output list doesn't include the policy contents. To see the content for a policy, see <a>DescribePolicy</a>.</p>
#[serde(rename = "Policies")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policies: Option<Vec<PolicySummary>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListRootsRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListRootsResponse {
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>A list of roots that are defined in an organization.</p>
#[serde(rename = "Roots")]
#[serde(skip_serializing_if = "Option::is_none")]
pub roots: Option<Vec<Root>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListTagsForResourceRequest {
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p><p>The ID of the resource with the tags to list.</p> <p>You can specify any of the following taggable resources.</p> <ul> <li> <p>AWS account – specify the account ID number.</p> </li> <li> <p>Organizational unit – specify the OU ID that begins with <code>ou-</code> and looks similar to: <code>ou-<i>1a2b-34uvwxyz</i> </code> </p> </li> <li> <p>Root – specify the root ID that begins with <code>r-</code> and looks similar to: <code>r-<i>1a2b</i> </code> </p> </li> <li> <p>Policy – specify the policy ID that begins with <code>p-</code> andlooks similar to: <code>p-<i>12abcdefg3</i> </code> </p> </li> </ul></p>
#[serde(rename = "ResourceId")]
pub resource_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListTagsForResourceResponse {
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>The tags that are assigned to the resource.</p>
#[serde(rename = "Tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListTargetsForPolicyRequest {
/// <p>The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the <code>NextToken</code> response element is present and has a value (is not null). Include that value as the <code>NextToken</code> request parameter in the next call to the operation to get the next part of the results. Note that Organizations might return fewer results than the maximum even when there are more results available. You should check <code>NextToken</code> after every operation to ensure that you receive all of the results.</p>
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
/// <p>The parameter for receiving additional results if you receive a <code>NextToken</code> response in a previous request. A <code>NextToken</code> response indicates that more output is available. Set this parameter to the value of the previous call's <code>NextToken</code> response to indicate where the output should continue from.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>The unique identifier (ID) of the policy whose attachments you want to know.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a policy ID string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).</p>
#[serde(rename = "PolicyId")]
pub policy_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListTargetsForPolicyResponse {
/// <p>If present, indicates that more output is available than is included in the current response. Use this value in the <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>.</p>
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
/// <p>A list of structures, each of which contains details about one of the entities to which the specified policy is attached.</p>
#[serde(rename = "Targets")]
#[serde(skip_serializing_if = "Option::is_none")]
pub targets: Option<Vec<PolicyTargetSummary>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct MoveAccountRequest {
/// <p>The unique identifier (ID) of the account that you want to move.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an account ID string requires exactly 12 digits.</p>
#[serde(rename = "AccountId")]
pub account_id: String,
/// <p><p>The unique identifier (ID) of the root or organizational unit that you want to move the account to.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a parent ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "DestinationParentId")]
pub destination_parent_id: String,
/// <p><p>The unique identifier (ID) of the root or organizational unit that you want to move the account from.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a parent ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "SourceParentId")]
pub source_parent_id: String,
}
/// <p>Contains details about an organization. An organization is a collection of accounts that are centrally managed together using consolidated billing, organized hierarchically with organizational units (OUs), and controlled with policies .</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Organization {
/// <p>The Amazon Resource Name (ARN) of an organization.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p><important> <p>Do not use. This field is deprecated and doesn't provide complete information about the policies in your organization.</p> </important> <p>To determine the policies that are enabled and available for use in your organization, use the <a>ListRoots</a> operation instead.</p></p>
#[serde(rename = "AvailablePolicyTypes")]
#[serde(skip_serializing_if = "Option::is_none")]
pub available_policy_types: Option<Vec<PolicyTypeSummary>>,
/// <p>Specifies the functionality that currently is available to the organization. If set to "ALL", then all features are enabled and policies can be applied to accounts in the organization. If set to "CONSOLIDATED_BILLING", then only consolidated billing functionality is available. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">Enabling All Features in Your Organization</a> in the <i>AWS Organizations User Guide</i>.</p>
#[serde(rename = "FeatureSet")]
#[serde(skip_serializing_if = "Option::is_none")]
pub feature_set: Option<String>,
/// <p>The unique identifier (ID) of an organization.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an organization ID string requires "o-" followed by from 10 to 32 lowercase letters or digits.</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The Amazon Resource Name (ARN) of the account that is designated as the management account for the organization.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "MasterAccountArn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub master_account_arn: Option<String>,
/// <p>The email address that is associated with the AWS account that is designated as the management account for the organization.</p>
#[serde(rename = "MasterAccountEmail")]
#[serde(skip_serializing_if = "Option::is_none")]
pub master_account_email: Option<String>,
/// <p>The unique identifier (ID) of the management account of an organization.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an account ID string requires exactly 12 digits.</p>
#[serde(rename = "MasterAccountId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub master_account_id: Option<String>,
}
/// <p>Contains details about an organizational unit (OU). An OU is a container of AWS accounts within a root of an organization. Policies that are attached to an OU apply to all accounts contained in that OU and in any child OUs.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct OrganizationalUnit {
/// <p>The Amazon Resource Name (ARN) of this OU.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p>The unique identifier (ID) associated with this OU.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an organizational unit ID string requires "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that contains the OU). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The friendly name of this OU.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
}
/// <p>Contains information about either a root or an organizational unit (OU) that can contain OUs or accounts in an organization.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Parent {
/// <p><p>The unique identifier (ID) of the parent entity.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a parent ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The type of the parent entity.</p>
#[serde(rename = "Type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
}
/// <p>Contains rules to be applied to the affected accounts. Policies can be attached directly to accounts, or to roots and OUs to affect all accounts in those hierarchies.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Policy {
/// <p>The text content of the policy.</p>
#[serde(rename = "Content")]
#[serde(skip_serializing_if = "Option::is_none")]
pub content: Option<String>,
/// <p>A structure that contains additional details about the policy.</p>
#[serde(rename = "PolicySummary")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policy_summary: Option<PolicySummary>,
}
/// <p>Contains information about a policy, but does not include the content. To see the content of a policy, see <a>DescribePolicy</a>.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PolicySummary {
/// <p>The Amazon Resource Name (ARN) of the policy.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p>A boolean value that indicates whether the specified policy is an AWS managed policy. If true, then you can attach the policy to roots, OUs, or accounts, but you cannot edit it.</p>
#[serde(rename = "AwsManaged")]
#[serde(skip_serializing_if = "Option::is_none")]
pub aws_managed: Option<bool>,
/// <p>The description of the policy.</p>
#[serde(rename = "Description")]
#[serde(skip_serializing_if = "Option::is_none")]
pub description: Option<String>,
/// <p>The unique identifier (ID) of the policy.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a policy ID string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The friendly name of the policy.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
/// <p>The type of policy.</p>
#[serde(rename = "Type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
}
/// <p>Contains information about a root, OU, or account that a policy is attached to.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PolicyTargetSummary {
/// <p>The Amazon Resource Name (ARN) of the policy target.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p>The friendly name of the policy target.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
/// <p><p>The unique identifier (ID) of the policy target.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a target ID string requires one of the following:</p> <ul> <li> <p> <b>Root</b> - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.</p> </li> <li> <p> <b>Account</b> - A string that consists of exactly 12 digits.</p> </li> <li> <p> <b>Organizational unit (OU)</b> - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p> </li> </ul></p>
#[serde(rename = "TargetId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub target_id: Option<String>,
/// <p>The type of the policy target.</p>
#[serde(rename = "Type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
}
/// <p>Contains information about a policy type and its status in the associated root.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PolicyTypeSummary {
/// <p>The status of the policy type as it relates to the associated root. To attach a policy of the specified type to a root or to an OU or account in that root, it must be available in the organization and enabled for that root.</p>
#[serde(rename = "Status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
/// <p>The name of the policy type.</p>
#[serde(rename = "Type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct RegisterDelegatedAdministratorRequest {
/// <p>The account ID number of the member account in the organization to register as a delegated administrator.</p>
#[serde(rename = "AccountId")]
pub account_id: String,
/// <p>The service principal of the AWS service for which you want to make the member account a delegated administrator.</p>
#[serde(rename = "ServicePrincipal")]
pub service_principal: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct RemoveAccountFromOrganizationRequest {
/// <p>The unique identifier (ID) of the member account that you want to remove from the organization.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an account ID string requires exactly 12 digits.</p>
#[serde(rename = "AccountId")]
pub account_id: String,
}
/// <p>Contains details about a root. A root is a top-level parent node in the hierarchy of an organization that can contain organizational units (OUs) and accounts. The root contains every AWS account in the organization.</p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Root {
/// <p>The Amazon Resource Name (ARN) of the root.</p> <p>For more information about ARNs in Organizations, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsorganizations.html#awsorganizations-resources-for-iam-policies">ARN Formats Supported by Organizations</a> in the <i>AWS Service Authorization Reference</i>.</p>
#[serde(rename = "Arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
/// <p>The unique identifier (ID) for the root.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a root ID string requires "r-" followed by from 4 to 32 lowercase letters or digits.</p>
#[serde(rename = "Id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
/// <p>The friendly name of the root.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
/// <p><p>The types of policies that are currently enabled for the root and therefore can be attached to the root or to its OUs or accounts.</p> <note> <p>Even if a policy type is shown as available in the organization, you can separately enable and disable them at the root level by using <a>EnablePolicyType</a> and <a>DisablePolicyType</a>. Use <a>DescribeOrganization</a> to see the availability of the policy types in that organization.</p> </note></p>
#[serde(rename = "PolicyTypes")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policy_types: Option<Vec<PolicyTypeSummary>>,
}
/// <p><p>A custom key-value pair associated with a resource within your organization.</p> <p>You can attach tags to any of the following organization resources.</p> <ul> <li> <p>AWS account</p> </li> <li> <p>Organizational unit (OU)</p> </li> <li> <p>Organization root</p> </li> <li> <p>Policy</p> </li> </ul></p>
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct Tag {
/// <p>The key identifier, or name, of the tag.</p>
#[serde(rename = "Key")]
pub key: String,
/// <p>The string value that's associated with the key of the tag. You can set the value of a tag to an empty string, but you can't set the value of a tag to null.</p>
#[serde(rename = "Value")]
pub value: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct TagResourceRequest {
/// <p>The ID of the resource to add a tag to.</p>
#[serde(rename = "ResourceId")]
pub resource_id: String,
/// <p><p>A list of tags to add to the specified resource.</p> <p>You can specify any of the following taggable resources.</p> <ul> <li> <p>AWS account – specify the account ID number.</p> </li> <li> <p>Organizational unit – specify the OU ID that begins with <code>ou-</code> and looks similar to: <code>ou-<i>1a2b-34uvwxyz</i> </code> </p> </li> <li> <p>Root – specify the root ID that begins with <code>r-</code> and looks similar to: <code>r-<i>1a2b</i> </code> </p> </li> <li> <p>Policy – specify the policy ID that begins with <code>p-</code> andlooks similar to: <code>p-<i>12abcdefg3</i> </code> </p> </li> </ul> <p>For each tag in the list, you must specify both a tag key and a value. You can set the value to an empty string, but you can't set it to <code>null</code>.</p> <note> <p>If any one of the tags is invalid or if you exceed the allowed number of tags for an account user, then the entire request fails and the account is not created.</p> </note></p>
#[serde(rename = "Tags")]
pub tags: Vec<Tag>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct UntagResourceRequest {
/// <p><p>The ID of the resource to remove a tag from.</p> <p>You can specify any of the following taggable resources.</p> <ul> <li> <p>AWS account – specify the account ID number.</p> </li> <li> <p>Organizational unit – specify the OU ID that begins with <code>ou-</code> and looks similar to: <code>ou-<i>1a2b-34uvwxyz</i> </code> </p> </li> <li> <p>Root – specify the root ID that begins with <code>r-</code> and looks similar to: <code>r-<i>1a2b</i> </code> </p> </li> <li> <p>Policy – specify the policy ID that begins with <code>p-</code> andlooks similar to: <code>p-<i>12abcdefg3</i> </code> </p> </li> </ul></p>
#[serde(rename = "ResourceId")]
pub resource_id: String,
/// <p>The list of keys for tags to remove from the specified resource.</p>
#[serde(rename = "TagKeys")]
pub tag_keys: Vec<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct UpdateOrganizationalUnitRequest {
/// <p>The new name that you want to assign to the OU.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
/// <p>The unique identifier (ID) of the OU that you want to rename. You can get the ID from the <a>ListOrganizationalUnitsForParent</a> operation.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for an organizational unit ID string requires "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that contains the OU). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.</p>
#[serde(rename = "OrganizationalUnitId")]
pub organizational_unit_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct UpdateOrganizationalUnitResponse {
/// <p>A structure that contains the details about the specified OU, including its new name.</p>
#[serde(rename = "OrganizationalUnit")]
#[serde(skip_serializing_if = "Option::is_none")]
pub organizational_unit: Option<OrganizationalUnit>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct UpdatePolicyRequest {
/// <p>If provided, the new content for the policy. The text must be correctly formatted JSON that complies with the syntax for the policy's type. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html">Service Control Policy Syntax</a> in the <i>AWS Organizations User Guide.</i> </p>
#[serde(rename = "Content")]
#[serde(skip_serializing_if = "Option::is_none")]
pub content: Option<String>,
/// <p>If provided, the new description for the policy.</p>
#[serde(rename = "Description")]
#[serde(skip_serializing_if = "Option::is_none")]
pub description: Option<String>,
/// <p>If provided, the new name for the policy.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> that is used to validate this parameter is a string of any of the characters in the ASCII character range.</p>
#[serde(rename = "Name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
/// <p>The unique identifier (ID) of the policy that you want to update.</p> <p>The <a href="http://wikipedia.org/wiki/regex">regex pattern</a> for a policy ID string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, digits, or the underscore character (_).</p>
#[serde(rename = "PolicyId")]
pub policy_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct UpdatePolicyResponse {
/// <p>A structure that contains details about the updated policy, showing the requested changes.</p>
#[serde(rename = "Policy")]
#[serde(skip_serializing_if = "Option::is_none")]
pub policy: Option<Policy>,
}
/// Errors returned by AcceptHandshake
#[derive(Debug, PartialEq)]
pub enum AcceptHandshakeError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The operation that you attempted requires you to have the <code>iam:CreateServiceLinkedRole</code> for <code>organizations.amazonaws.com</code> permission so that AWS Organizations can create the required service-linked role. You don't have that permission.</p>
AccessDeniedForDependency(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p>The specified handshake is already in the requested state. For example, you can't accept a handshake that was already accepted.</p>
HandshakeAlreadyInState(String),
/// <p><p>The requested operation would violate the constraint identified in the reason code.</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation:</p> </note> <ul> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. Note that deleted and closed accounts still count toward your limit.</p> <important> <p>If you get this exception immediately after creating the organization, wait one hour and try again. If after an hour it continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>ALREADY</em>IN<em>AN</em>ORGANIZATION: The handshake request is invalid because the invited account is already a member of an organization.</p> </li> <li> <p>HANDSHAKE<em>RATE</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>INVITE</em>DISABLED<em>DURING</em>ENABLE<em>ALL</em>FEATURES: You can't issue new invitations to join an organization while it's in the process of enabling all features. You can resume inviting accounts after you finalize the process when all accounts have agreed to the change.</p> </li> <li> <p>ORGANIZATION<em>ALREADY</em>HAS<em>ALL</em>FEATURES: The handshake request is invalid because the organization has already enabled all features.</p> </li> <li> <p>ORGANIZATION<em>IS</em>ALREADY<em>PENDING</em>ALL<em>FEATURES</em>MIGRATION: The handshake request is invalid because the organization has already started the process to enable all features.</p> </li> <li> <p>ORGANIZATION<em>FROM</em>DIFFERENT<em>SELLER</em>OF<em>RECORD: The request failed because the account is from a different marketplace than the accounts in the organization. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be from the same marketplace.</p> </li> <li> <p>ORGANIZATION</em>MEMBERSHIP<em>CHANGE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to change the membership of an account too quickly after its previous change.</p> </li> <li> <p>PAYMENT<em>INSTRUMENT</em>REQUIRED: You can't complete the operation with an account that doesn't have a payment instrument, such as a credit card, associated with it.</p> </li> </ul></p>
HandshakeConstraintViolation(String),
/// <p>We can't find a handshake with the <code>HandshakeId</code> that you specified.</p>
HandshakeNotFound(String),
/// <p>You can't perform the operation on the handshake in its current state. For example, you can't cancel a handshake that was already accepted or accept a handshake that was already declined.</p>
InvalidHandshakeTransition(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl AcceptHandshakeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<AcceptHandshakeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(AcceptHandshakeError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(AcceptHandshakeError::AccessDenied(err.msg))
}
"AccessDeniedForDependencyException" => {
return RusotoError::Service(AcceptHandshakeError::AccessDeniedForDependency(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(AcceptHandshakeError::ConcurrentModification(
err.msg,
))
}
"HandshakeAlreadyInStateException" => {
return RusotoError::Service(AcceptHandshakeError::HandshakeAlreadyInState(
err.msg,
))
}
"HandshakeConstraintViolationException" => {
return RusotoError::Service(
AcceptHandshakeError::HandshakeConstraintViolation(err.msg),
)
}
"HandshakeNotFoundException" => {
return RusotoError::Service(AcceptHandshakeError::HandshakeNotFound(err.msg))
}
"InvalidHandshakeTransitionException" => {
return RusotoError::Service(AcceptHandshakeError::InvalidHandshakeTransition(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(AcceptHandshakeError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(AcceptHandshakeError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(AcceptHandshakeError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for AcceptHandshakeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
AcceptHandshakeError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::AccessDenied(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::AccessDeniedForDependency(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::HandshakeAlreadyInState(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::HandshakeConstraintViolation(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::HandshakeNotFound(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::InvalidHandshakeTransition(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::InvalidInput(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::Service(ref cause) => write!(f, "{}", cause),
AcceptHandshakeError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for AcceptHandshakeError {}
/// Errors returned by AttachPolicy
#[derive(Debug, PartialEq)]
pub enum AttachPolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>The selected policy is already attached to the specified target.</p>
DuplicatePolicyAttachment(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>Changes to the effective policy are in progress, and its contents can't be returned. Try the operation again later. </p>
PolicyChangesInProgress(String),
/// <p>We can't find a policy with the <code>PolicyId</code> that you specified.</p>
PolicyNotFound(String),
/// <p>The specified policy type isn't currently enabled in this root. You can't attach policies of the specified type to entities in a root until you enable that type in the root. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">Enabling All Features in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p>
PolicyTypeNotEnabled(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a root, OU, account, or policy with the <code>TargetId</code> that you specified.</p>
TargetNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl AttachPolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<AttachPolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(AttachPolicyError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(AttachPolicyError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(AttachPolicyError::ConcurrentModification(err.msg))
}
"ConstraintViolationException" => {
return RusotoError::Service(AttachPolicyError::ConstraintViolation(err.msg))
}
"DuplicatePolicyAttachmentException" => {
return RusotoError::Service(AttachPolicyError::DuplicatePolicyAttachment(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(AttachPolicyError::InvalidInput(err.msg))
}
"PolicyChangesInProgressException" => {
return RusotoError::Service(AttachPolicyError::PolicyChangesInProgress(
err.msg,
))
}
"PolicyNotFoundException" => {
return RusotoError::Service(AttachPolicyError::PolicyNotFound(err.msg))
}
"PolicyTypeNotEnabledException" => {
return RusotoError::Service(AttachPolicyError::PolicyTypeNotEnabled(err.msg))
}
"ServiceException" => {
return RusotoError::Service(AttachPolicyError::Service(err.msg))
}
"TargetNotFoundException" => {
return RusotoError::Service(AttachPolicyError::TargetNotFound(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(AttachPolicyError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(AttachPolicyError::UnsupportedAPIEndpoint(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for AttachPolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
AttachPolicyError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
AttachPolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
AttachPolicyError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
AttachPolicyError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
AttachPolicyError::DuplicatePolicyAttachment(ref cause) => write!(f, "{}", cause),
AttachPolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
AttachPolicyError::PolicyChangesInProgress(ref cause) => write!(f, "{}", cause),
AttachPolicyError::PolicyNotFound(ref cause) => write!(f, "{}", cause),
AttachPolicyError::PolicyTypeNotEnabled(ref cause) => write!(f, "{}", cause),
AttachPolicyError::Service(ref cause) => write!(f, "{}", cause),
AttachPolicyError::TargetNotFound(ref cause) => write!(f, "{}", cause),
AttachPolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
AttachPolicyError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for AttachPolicyError {}
/// Errors returned by CancelHandshake
#[derive(Debug, PartialEq)]
pub enum CancelHandshakeError {
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p>The specified handshake is already in the requested state. For example, you can't accept a handshake that was already accepted.</p>
HandshakeAlreadyInState(String),
/// <p>We can't find a handshake with the <code>HandshakeId</code> that you specified.</p>
HandshakeNotFound(String),
/// <p>You can't perform the operation on the handshake in its current state. For example, you can't cancel a handshake that was already accepted or accept a handshake that was already declined.</p>
InvalidHandshakeTransition(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl CancelHandshakeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CancelHandshakeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AccessDeniedException" => {
return RusotoError::Service(CancelHandshakeError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(CancelHandshakeError::ConcurrentModification(
err.msg,
))
}
"HandshakeAlreadyInStateException" => {
return RusotoError::Service(CancelHandshakeError::HandshakeAlreadyInState(
err.msg,
))
}
"HandshakeNotFoundException" => {
return RusotoError::Service(CancelHandshakeError::HandshakeNotFound(err.msg))
}
"InvalidHandshakeTransitionException" => {
return RusotoError::Service(CancelHandshakeError::InvalidHandshakeTransition(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(CancelHandshakeError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(CancelHandshakeError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(CancelHandshakeError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CancelHandshakeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CancelHandshakeError::AccessDenied(ref cause) => write!(f, "{}", cause),
CancelHandshakeError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
CancelHandshakeError::HandshakeAlreadyInState(ref cause) => write!(f, "{}", cause),
CancelHandshakeError::HandshakeNotFound(ref cause) => write!(f, "{}", cause),
CancelHandshakeError::InvalidHandshakeTransition(ref cause) => write!(f, "{}", cause),
CancelHandshakeError::InvalidInput(ref cause) => write!(f, "{}", cause),
CancelHandshakeError::Service(ref cause) => write!(f, "{}", cause),
CancelHandshakeError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CancelHandshakeError {}
/// Errors returned by CreateAccount
#[derive(Debug, PartialEq)]
pub enum CreateAccountError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>AWS Organizations couldn't perform the operation because your organization hasn't finished initializing. This can take up to an hour. Try again later. If after one hour you continue to receive this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p>
FinalizingOrganization(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl CreateAccountError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateAccountError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(CreateAccountError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(CreateAccountError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(CreateAccountError::ConcurrentModification(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(CreateAccountError::ConstraintViolation(err.msg))
}
"FinalizingOrganizationException" => {
return RusotoError::Service(CreateAccountError::FinalizingOrganization(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(CreateAccountError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(CreateAccountError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(CreateAccountError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(CreateAccountError::UnsupportedAPIEndpoint(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CreateAccountError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CreateAccountError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
CreateAccountError::AccessDenied(ref cause) => write!(f, "{}", cause),
CreateAccountError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
CreateAccountError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
CreateAccountError::FinalizingOrganization(ref cause) => write!(f, "{}", cause),
CreateAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
CreateAccountError::Service(ref cause) => write!(f, "{}", cause),
CreateAccountError::TooManyRequests(ref cause) => write!(f, "{}", cause),
CreateAccountError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CreateAccountError {}
/// Errors returned by CreateGovCloudAccount
#[derive(Debug, PartialEq)]
pub enum CreateGovCloudAccountError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>AWS Organizations couldn't perform the operation because your organization hasn't finished initializing. This can take up to an hour. Try again later. If after one hour you continue to receive this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p>
FinalizingOrganization(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl CreateGovCloudAccountError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateGovCloudAccountError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
CreateGovCloudAccountError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(CreateGovCloudAccountError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
CreateGovCloudAccountError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(CreateGovCloudAccountError::ConstraintViolation(
err.msg,
))
}
"FinalizingOrganizationException" => {
return RusotoError::Service(
CreateGovCloudAccountError::FinalizingOrganization(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(CreateGovCloudAccountError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(CreateGovCloudAccountError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(CreateGovCloudAccountError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
CreateGovCloudAccountError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CreateGovCloudAccountError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CreateGovCloudAccountError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
CreateGovCloudAccountError::AccessDenied(ref cause) => write!(f, "{}", cause),
CreateGovCloudAccountError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
CreateGovCloudAccountError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
CreateGovCloudAccountError::FinalizingOrganization(ref cause) => write!(f, "{}", cause),
CreateGovCloudAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
CreateGovCloudAccountError::Service(ref cause) => write!(f, "{}", cause),
CreateGovCloudAccountError::TooManyRequests(ref cause) => write!(f, "{}", cause),
CreateGovCloudAccountError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CreateGovCloudAccountError {}
/// Errors returned by CreateOrganization
#[derive(Debug, PartialEq)]
pub enum CreateOrganizationError {
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The operation that you attempted requires you to have the <code>iam:CreateServiceLinkedRole</code> for <code>organizations.amazonaws.com</code> permission so that AWS Organizations can create the required service-linked role. You don't have that permission.</p>
AccessDeniedForDependency(String),
/// <p>This account is already a member of an organization. An account can belong to only one organization at a time.</p>
AlreadyInOrganization(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl CreateOrganizationError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AccessDeniedException" => {
return RusotoError::Service(CreateOrganizationError::AccessDenied(err.msg))
}
"AccessDeniedForDependencyException" => {
return RusotoError::Service(
CreateOrganizationError::AccessDeniedForDependency(err.msg),
)
}
"AlreadyInOrganizationException" => {
return RusotoError::Service(CreateOrganizationError::AlreadyInOrganization(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(CreateOrganizationError::ConcurrentModification(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(CreateOrganizationError::ConstraintViolation(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(CreateOrganizationError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(CreateOrganizationError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(CreateOrganizationError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CreateOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CreateOrganizationError::AccessDenied(ref cause) => write!(f, "{}", cause),
CreateOrganizationError::AccessDeniedForDependency(ref cause) => write!(f, "{}", cause),
CreateOrganizationError::AlreadyInOrganization(ref cause) => write!(f, "{}", cause),
CreateOrganizationError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
CreateOrganizationError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
CreateOrganizationError::InvalidInput(ref cause) => write!(f, "{}", cause),
CreateOrganizationError::Service(ref cause) => write!(f, "{}", cause),
CreateOrganizationError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CreateOrganizationError {}
/// Errors returned by CreateOrganizationalUnit
#[derive(Debug, PartialEq)]
pub enum CreateOrganizationalUnitError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>An OU with the same name already exists.</p>
DuplicateOrganizationalUnit(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find a root or OU with the <code>ParentId</code> that you specified.</p>
ParentNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl CreateOrganizationalUnitError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateOrganizationalUnitError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
CreateOrganizationalUnitError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(CreateOrganizationalUnitError::AccessDenied(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
CreateOrganizationalUnitError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(
CreateOrganizationalUnitError::ConstraintViolation(err.msg),
)
}
"DuplicateOrganizationalUnitException" => {
return RusotoError::Service(
CreateOrganizationalUnitError::DuplicateOrganizationalUnit(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(CreateOrganizationalUnitError::InvalidInput(
err.msg,
))
}
"ParentNotFoundException" => {
return RusotoError::Service(CreateOrganizationalUnitError::ParentNotFound(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(CreateOrganizationalUnitError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(CreateOrganizationalUnitError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CreateOrganizationalUnitError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CreateOrganizationalUnitError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
CreateOrganizationalUnitError::AccessDenied(ref cause) => write!(f, "{}", cause),
CreateOrganizationalUnitError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
CreateOrganizationalUnitError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
CreateOrganizationalUnitError::DuplicateOrganizationalUnit(ref cause) => {
write!(f, "{}", cause)
}
CreateOrganizationalUnitError::InvalidInput(ref cause) => write!(f, "{}", cause),
CreateOrganizationalUnitError::ParentNotFound(ref cause) => write!(f, "{}", cause),
CreateOrganizationalUnitError::Service(ref cause) => write!(f, "{}", cause),
CreateOrganizationalUnitError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CreateOrganizationalUnitError {}
/// Errors returned by CreatePolicy
#[derive(Debug, PartialEq)]
pub enum CreatePolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>A policy with the same name already exists.</p>
DuplicatePolicy(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>The provided policy document doesn't meet the requirements of the specified policy type. For example, the syntax might be incorrect. For details about service control policy syntax, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html">Service Control Policy Syntax</a> in the <i>AWS Organizations User Guide.</i> </p>
MalformedPolicyDocument(String),
/// <p>You can't use the specified policy type with the feature set currently enabled for this organization. For example, you can enable SCPs only after you enable all features in the organization. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html#enable_policies_on_root">Managing AWS Organizations Policies</a>in the <i>AWS Organizations User Guide.</i> </p>
PolicyTypeNotAvailableForOrganization(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl CreatePolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreatePolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(CreatePolicyError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(CreatePolicyError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(CreatePolicyError::ConcurrentModification(err.msg))
}
"ConstraintViolationException" => {
return RusotoError::Service(CreatePolicyError::ConstraintViolation(err.msg))
}
"DuplicatePolicyException" => {
return RusotoError::Service(CreatePolicyError::DuplicatePolicy(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(CreatePolicyError::InvalidInput(err.msg))
}
"MalformedPolicyDocumentException" => {
return RusotoError::Service(CreatePolicyError::MalformedPolicyDocument(
err.msg,
))
}
"PolicyTypeNotAvailableForOrganizationException" => {
return RusotoError::Service(
CreatePolicyError::PolicyTypeNotAvailableForOrganization(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(CreatePolicyError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(CreatePolicyError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(CreatePolicyError::UnsupportedAPIEndpoint(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CreatePolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CreatePolicyError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
CreatePolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
CreatePolicyError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
CreatePolicyError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
CreatePolicyError::DuplicatePolicy(ref cause) => write!(f, "{}", cause),
CreatePolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
CreatePolicyError::MalformedPolicyDocument(ref cause) => write!(f, "{}", cause),
CreatePolicyError::PolicyTypeNotAvailableForOrganization(ref cause) => {
write!(f, "{}", cause)
}
CreatePolicyError::Service(ref cause) => write!(f, "{}", cause),
CreatePolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
CreatePolicyError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CreatePolicyError {}
/// Errors returned by DeclineHandshake
#[derive(Debug, PartialEq)]
pub enum DeclineHandshakeError {
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p>The specified handshake is already in the requested state. For example, you can't accept a handshake that was already accepted.</p>
HandshakeAlreadyInState(String),
/// <p>We can't find a handshake with the <code>HandshakeId</code> that you specified.</p>
HandshakeNotFound(String),
/// <p>You can't perform the operation on the handshake in its current state. For example, you can't cancel a handshake that was already accepted or accept a handshake that was already declined.</p>
InvalidHandshakeTransition(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl DeclineHandshakeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeclineHandshakeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AccessDeniedException" => {
return RusotoError::Service(DeclineHandshakeError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(DeclineHandshakeError::ConcurrentModification(
err.msg,
))
}
"HandshakeAlreadyInStateException" => {
return RusotoError::Service(DeclineHandshakeError::HandshakeAlreadyInState(
err.msg,
))
}
"HandshakeNotFoundException" => {
return RusotoError::Service(DeclineHandshakeError::HandshakeNotFound(err.msg))
}
"InvalidHandshakeTransitionException" => {
return RusotoError::Service(DeclineHandshakeError::InvalidHandshakeTransition(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(DeclineHandshakeError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(DeclineHandshakeError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DeclineHandshakeError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeclineHandshakeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeclineHandshakeError::AccessDenied(ref cause) => write!(f, "{}", cause),
DeclineHandshakeError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
DeclineHandshakeError::HandshakeAlreadyInState(ref cause) => write!(f, "{}", cause),
DeclineHandshakeError::HandshakeNotFound(ref cause) => write!(f, "{}", cause),
DeclineHandshakeError::InvalidHandshakeTransition(ref cause) => write!(f, "{}", cause),
DeclineHandshakeError::InvalidInput(ref cause) => write!(f, "{}", cause),
DeclineHandshakeError::Service(ref cause) => write!(f, "{}", cause),
DeclineHandshakeError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DeclineHandshakeError {}
/// Errors returned by DeleteOrganization
#[derive(Debug, PartialEq)]
pub enum DeleteOrganizationError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>The organization isn't empty. To delete an organization, you must first remove all accounts except the management account, delete all OUs, and delete all policies.</p>
OrganizationNotEmpty(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl DeleteOrganizationError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(DeleteOrganizationError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(DeleteOrganizationError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(DeleteOrganizationError::ConcurrentModification(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(DeleteOrganizationError::InvalidInput(err.msg))
}
"OrganizationNotEmptyException" => {
return RusotoError::Service(DeleteOrganizationError::OrganizationNotEmpty(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(DeleteOrganizationError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DeleteOrganizationError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeleteOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeleteOrganizationError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
DeleteOrganizationError::AccessDenied(ref cause) => write!(f, "{}", cause),
DeleteOrganizationError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
DeleteOrganizationError::InvalidInput(ref cause) => write!(f, "{}", cause),
DeleteOrganizationError::OrganizationNotEmpty(ref cause) => write!(f, "{}", cause),
DeleteOrganizationError::Service(ref cause) => write!(f, "{}", cause),
DeleteOrganizationError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DeleteOrganizationError {}
/// Errors returned by DeleteOrganizationalUnit
#[derive(Debug, PartialEq)]
pub enum DeleteOrganizationalUnitError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>The specified OU is not empty. Move all accounts to another root or to other OUs, remove all child OUs, and try the operation again.</p>
OrganizationalUnitNotEmpty(String),
/// <p>We can't find an OU with the <code>OrganizationalUnitId</code> that you specified.</p>
OrganizationalUnitNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl DeleteOrganizationalUnitError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteOrganizationalUnitError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
DeleteOrganizationalUnitError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(DeleteOrganizationalUnitError::AccessDenied(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
DeleteOrganizationalUnitError::ConcurrentModification(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(DeleteOrganizationalUnitError::InvalidInput(
err.msg,
))
}
"OrganizationalUnitNotEmptyException" => {
return RusotoError::Service(
DeleteOrganizationalUnitError::OrganizationalUnitNotEmpty(err.msg),
)
}
"OrganizationalUnitNotFoundException" => {
return RusotoError::Service(
DeleteOrganizationalUnitError::OrganizationalUnitNotFound(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(DeleteOrganizationalUnitError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DeleteOrganizationalUnitError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeleteOrganizationalUnitError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeleteOrganizationalUnitError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
DeleteOrganizationalUnitError::AccessDenied(ref cause) => write!(f, "{}", cause),
DeleteOrganizationalUnitError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
DeleteOrganizationalUnitError::InvalidInput(ref cause) => write!(f, "{}", cause),
DeleteOrganizationalUnitError::OrganizationalUnitNotEmpty(ref cause) => {
write!(f, "{}", cause)
}
DeleteOrganizationalUnitError::OrganizationalUnitNotFound(ref cause) => {
write!(f, "{}", cause)
}
DeleteOrganizationalUnitError::Service(ref cause) => write!(f, "{}", cause),
DeleteOrganizationalUnitError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DeleteOrganizationalUnitError {}
/// Errors returned by DeletePolicy
#[derive(Debug, PartialEq)]
pub enum DeletePolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>The policy is attached to one or more entities. You must detach it from all roots, OUs, and accounts before performing this operation.</p>
PolicyInUse(String),
/// <p>We can't find a policy with the <code>PolicyId</code> that you specified.</p>
PolicyNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DeletePolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeletePolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(DeletePolicyError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(DeletePolicyError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(DeletePolicyError::ConcurrentModification(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(DeletePolicyError::InvalidInput(err.msg))
}
"PolicyInUseException" => {
return RusotoError::Service(DeletePolicyError::PolicyInUse(err.msg))
}
"PolicyNotFoundException" => {
return RusotoError::Service(DeletePolicyError::PolicyNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(DeletePolicyError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DeletePolicyError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(DeletePolicyError::UnsupportedAPIEndpoint(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeletePolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeletePolicyError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
DeletePolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
DeletePolicyError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
DeletePolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
DeletePolicyError::PolicyInUse(ref cause) => write!(f, "{}", cause),
DeletePolicyError::PolicyNotFound(ref cause) => write!(f, "{}", cause),
DeletePolicyError::Service(ref cause) => write!(f, "{}", cause),
DeletePolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
DeletePolicyError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DeletePolicyError {}
/// Errors returned by DeregisterDelegatedAdministrator
#[derive(Debug, PartialEq)]
pub enum DeregisterDelegatedAdministratorError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p> We can't find an AWS account with the <code>AccountId</code> that you specified, or the account whose credentials you used to make this request isn't a member of an organization.</p>
AccountNotFound(String),
/// <p>The specified account is not a delegated administrator for this AWS service. </p>
AccountNotRegistered(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DeregisterDelegatedAdministratorError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<DeregisterDelegatedAdministratorError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::AccessDenied(err.msg),
)
}
"AccountNotFoundException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::AccountNotFound(err.msg),
)
}
"AccountNotRegisteredException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::AccountNotRegistered(err.msg),
)
}
"ConcurrentModificationException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::ConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::InvalidInput(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(DeregisterDelegatedAdministratorError::Service(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::TooManyRequests(err.msg),
)
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
DeregisterDelegatedAdministratorError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeregisterDelegatedAdministratorError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeregisterDelegatedAdministratorError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::AccessDenied(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::AccountNotFound(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::AccountNotRegistered(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::ConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::InvalidInput(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::Service(ref cause) => write!(f, "{}", cause),
DeregisterDelegatedAdministratorError::TooManyRequests(ref cause) => {
write!(f, "{}", cause)
}
DeregisterDelegatedAdministratorError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for DeregisterDelegatedAdministratorError {}
/// Errors returned by DescribeAccount
#[derive(Debug, PartialEq)]
pub enum DescribeAccountError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p> We can't find an AWS account with the <code>AccountId</code> that you specified, or the account whose credentials you used to make this request isn't a member of an organization.</p>
AccountNotFound(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl DescribeAccountError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeAccountError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(DescribeAccountError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(DescribeAccountError::AccessDenied(err.msg))
}
"AccountNotFoundException" => {
return RusotoError::Service(DescribeAccountError::AccountNotFound(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(DescribeAccountError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(DescribeAccountError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DescribeAccountError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DescribeAccountError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DescribeAccountError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
DescribeAccountError::AccessDenied(ref cause) => write!(f, "{}", cause),
DescribeAccountError::AccountNotFound(ref cause) => write!(f, "{}", cause),
DescribeAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
DescribeAccountError::Service(ref cause) => write!(f, "{}", cause),
DescribeAccountError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DescribeAccountError {}
/// Errors returned by DescribeCreateAccountStatus
#[derive(Debug, PartialEq)]
pub enum DescribeCreateAccountStatusError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>We can't find an create account request with the <code>CreateAccountRequestId</code> that you specified.</p>
CreateAccountStatusNotFound(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DescribeCreateAccountStatusError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<DescribeCreateAccountStatusError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
DescribeCreateAccountStatusError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(DescribeCreateAccountStatusError::AccessDenied(
err.msg,
))
}
"CreateAccountStatusNotFoundException" => {
return RusotoError::Service(
DescribeCreateAccountStatusError::CreateAccountStatusNotFound(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(DescribeCreateAccountStatusError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(DescribeCreateAccountStatusError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DescribeCreateAccountStatusError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
DescribeCreateAccountStatusError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DescribeCreateAccountStatusError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DescribeCreateAccountStatusError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
DescribeCreateAccountStatusError::AccessDenied(ref cause) => write!(f, "{}", cause),
DescribeCreateAccountStatusError::CreateAccountStatusNotFound(ref cause) => {
write!(f, "{}", cause)
}
DescribeCreateAccountStatusError::InvalidInput(ref cause) => write!(f, "{}", cause),
DescribeCreateAccountStatusError::Service(ref cause) => write!(f, "{}", cause),
DescribeCreateAccountStatusError::TooManyRequests(ref cause) => write!(f, "{}", cause),
DescribeCreateAccountStatusError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for DescribeCreateAccountStatusError {}
/// Errors returned by DescribeEffectivePolicy
#[derive(Debug, PartialEq)]
pub enum DescribeEffectivePolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>If you ran this action on the management account, this policy type is not enabled. If you ran the action on a member account, the account doesn't have an effective policy of this type. Contact the administrator of your organization about attaching a policy of this type to the account. </p>
EffectivePolicyNotFound(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a root, OU, account, or policy with the <code>TargetId</code> that you specified.</p>
TargetNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DescribeEffectivePolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeEffectivePolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
DescribeEffectivePolicyError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(DescribeEffectivePolicyError::AccessDenied(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(DescribeEffectivePolicyError::ConstraintViolation(
err.msg,
))
}
"EffectivePolicyNotFoundException" => {
return RusotoError::Service(
DescribeEffectivePolicyError::EffectivePolicyNotFound(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(DescribeEffectivePolicyError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(DescribeEffectivePolicyError::Service(err.msg))
}
"TargetNotFoundException" => {
return RusotoError::Service(DescribeEffectivePolicyError::TargetNotFound(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(DescribeEffectivePolicyError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
DescribeEffectivePolicyError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DescribeEffectivePolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DescribeEffectivePolicyError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
DescribeEffectivePolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
DescribeEffectivePolicyError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
DescribeEffectivePolicyError::EffectivePolicyNotFound(ref cause) => {
write!(f, "{}", cause)
}
DescribeEffectivePolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
DescribeEffectivePolicyError::Service(ref cause) => write!(f, "{}", cause),
DescribeEffectivePolicyError::TargetNotFound(ref cause) => write!(f, "{}", cause),
DescribeEffectivePolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
DescribeEffectivePolicyError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for DescribeEffectivePolicyError {}
/// Errors returned by DescribeHandshake
#[derive(Debug, PartialEq)]
pub enum DescribeHandshakeError {
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p>We can't find a handshake with the <code>HandshakeId</code> that you specified.</p>
HandshakeNotFound(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl DescribeHandshakeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeHandshakeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AccessDeniedException" => {
return RusotoError::Service(DescribeHandshakeError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(DescribeHandshakeError::ConcurrentModification(
err.msg,
))
}
"HandshakeNotFoundException" => {
return RusotoError::Service(DescribeHandshakeError::HandshakeNotFound(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(DescribeHandshakeError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(DescribeHandshakeError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DescribeHandshakeError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DescribeHandshakeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DescribeHandshakeError::AccessDenied(ref cause) => write!(f, "{}", cause),
DescribeHandshakeError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
DescribeHandshakeError::HandshakeNotFound(ref cause) => write!(f, "{}", cause),
DescribeHandshakeError::InvalidInput(ref cause) => write!(f, "{}", cause),
DescribeHandshakeError::Service(ref cause) => write!(f, "{}", cause),
DescribeHandshakeError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DescribeHandshakeError {}
/// Errors returned by DescribeOrganization
#[derive(Debug, PartialEq)]
pub enum DescribeOrganizationError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl DescribeOrganizationError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
DescribeOrganizationError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(DescribeOrganizationError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(DescribeOrganizationError::ConcurrentModification(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(DescribeOrganizationError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DescribeOrganizationError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DescribeOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DescribeOrganizationError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
DescribeOrganizationError::AccessDenied(ref cause) => write!(f, "{}", cause),
DescribeOrganizationError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
DescribeOrganizationError::Service(ref cause) => write!(f, "{}", cause),
DescribeOrganizationError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DescribeOrganizationError {}
/// Errors returned by DescribeOrganizationalUnit
#[derive(Debug, PartialEq)]
pub enum DescribeOrganizationalUnitError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find an OU with the <code>OrganizationalUnitId</code> that you specified.</p>
OrganizationalUnitNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl DescribeOrganizationalUnitError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<DescribeOrganizationalUnitError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
DescribeOrganizationalUnitError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(DescribeOrganizationalUnitError::AccessDenied(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(DescribeOrganizationalUnitError::InvalidInput(
err.msg,
))
}
"OrganizationalUnitNotFoundException" => {
return RusotoError::Service(
DescribeOrganizationalUnitError::OrganizationalUnitNotFound(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(DescribeOrganizationalUnitError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DescribeOrganizationalUnitError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DescribeOrganizationalUnitError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DescribeOrganizationalUnitError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
DescribeOrganizationalUnitError::AccessDenied(ref cause) => write!(f, "{}", cause),
DescribeOrganizationalUnitError::InvalidInput(ref cause) => write!(f, "{}", cause),
DescribeOrganizationalUnitError::OrganizationalUnitNotFound(ref cause) => {
write!(f, "{}", cause)
}
DescribeOrganizationalUnitError::Service(ref cause) => write!(f, "{}", cause),
DescribeOrganizationalUnitError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DescribeOrganizationalUnitError {}
/// Errors returned by DescribePolicy
#[derive(Debug, PartialEq)]
pub enum DescribePolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find a policy with the <code>PolicyId</code> that you specified.</p>
PolicyNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DescribePolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribePolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(DescribePolicyError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(DescribePolicyError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(DescribePolicyError::InvalidInput(err.msg))
}
"PolicyNotFoundException" => {
return RusotoError::Service(DescribePolicyError::PolicyNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(DescribePolicyError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DescribePolicyError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(DescribePolicyError::UnsupportedAPIEndpoint(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DescribePolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DescribePolicyError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
DescribePolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
DescribePolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
DescribePolicyError::PolicyNotFound(ref cause) => write!(f, "{}", cause),
DescribePolicyError::Service(ref cause) => write!(f, "{}", cause),
DescribePolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
DescribePolicyError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DescribePolicyError {}
/// Errors returned by DetachPolicy
#[derive(Debug, PartialEq)]
pub enum DetachPolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>Changes to the effective policy are in progress, and its contents can't be returned. Try the operation again later. </p>
PolicyChangesInProgress(String),
/// <p>The policy isn't attached to the specified target in the specified root.</p>
PolicyNotAttached(String),
/// <p>We can't find a policy with the <code>PolicyId</code> that you specified.</p>
PolicyNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a root, OU, account, or policy with the <code>TargetId</code> that you specified.</p>
TargetNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DetachPolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DetachPolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(DetachPolicyError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(DetachPolicyError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(DetachPolicyError::ConcurrentModification(err.msg))
}
"ConstraintViolationException" => {
return RusotoError::Service(DetachPolicyError::ConstraintViolation(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(DetachPolicyError::InvalidInput(err.msg))
}
"PolicyChangesInProgressException" => {
return RusotoError::Service(DetachPolicyError::PolicyChangesInProgress(
err.msg,
))
}
"PolicyNotAttachedException" => {
return RusotoError::Service(DetachPolicyError::PolicyNotAttached(err.msg))
}
"PolicyNotFoundException" => {
return RusotoError::Service(DetachPolicyError::PolicyNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(DetachPolicyError::Service(err.msg))
}
"TargetNotFoundException" => {
return RusotoError::Service(DetachPolicyError::TargetNotFound(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DetachPolicyError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(DetachPolicyError::UnsupportedAPIEndpoint(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DetachPolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DetachPolicyError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
DetachPolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
DetachPolicyError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
DetachPolicyError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
DetachPolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
DetachPolicyError::PolicyChangesInProgress(ref cause) => write!(f, "{}", cause),
DetachPolicyError::PolicyNotAttached(ref cause) => write!(f, "{}", cause),
DetachPolicyError::PolicyNotFound(ref cause) => write!(f, "{}", cause),
DetachPolicyError::Service(ref cause) => write!(f, "{}", cause),
DetachPolicyError::TargetNotFound(ref cause) => write!(f, "{}", cause),
DetachPolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
DetachPolicyError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DetachPolicyError {}
/// Errors returned by DisableAWSServiceAccess
#[derive(Debug, PartialEq)]
pub enum DisableAWSServiceAccessError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DisableAWSServiceAccessError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DisableAWSServiceAccessError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
DisableAWSServiceAccessError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(DisableAWSServiceAccessError::AccessDenied(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
DisableAWSServiceAccessError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(DisableAWSServiceAccessError::ConstraintViolation(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(DisableAWSServiceAccessError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(DisableAWSServiceAccessError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DisableAWSServiceAccessError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
DisableAWSServiceAccessError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DisableAWSServiceAccessError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DisableAWSServiceAccessError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
DisableAWSServiceAccessError::AccessDenied(ref cause) => write!(f, "{}", cause),
DisableAWSServiceAccessError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
DisableAWSServiceAccessError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
DisableAWSServiceAccessError::InvalidInput(ref cause) => write!(f, "{}", cause),
DisableAWSServiceAccessError::Service(ref cause) => write!(f, "{}", cause),
DisableAWSServiceAccessError::TooManyRequests(ref cause) => write!(f, "{}", cause),
DisableAWSServiceAccessError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for DisableAWSServiceAccessError {}
/// Errors returned by DisablePolicyType
#[derive(Debug, PartialEq)]
pub enum DisablePolicyTypeError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>Changes to the effective policy are in progress, and its contents can't be returned. Try the operation again later. </p>
PolicyChangesInProgress(String),
/// <p>The specified policy type isn't currently enabled in this root. You can't attach policies of the specified type to entities in a root until you enable that type in the root. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">Enabling All Features in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p>
PolicyTypeNotEnabled(String),
/// <p>We can't find a root with the <code>RootId</code> that you specified.</p>
RootNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl DisablePolicyTypeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DisablePolicyTypeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(DisablePolicyTypeError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(DisablePolicyTypeError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(DisablePolicyTypeError::ConcurrentModification(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(DisablePolicyTypeError::ConstraintViolation(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(DisablePolicyTypeError::InvalidInput(err.msg))
}
"PolicyChangesInProgressException" => {
return RusotoError::Service(DisablePolicyTypeError::PolicyChangesInProgress(
err.msg,
))
}
"PolicyTypeNotEnabledException" => {
return RusotoError::Service(DisablePolicyTypeError::PolicyTypeNotEnabled(
err.msg,
))
}
"RootNotFoundException" => {
return RusotoError::Service(DisablePolicyTypeError::RootNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(DisablePolicyTypeError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(DisablePolicyTypeError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(DisablePolicyTypeError::UnsupportedAPIEndpoint(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DisablePolicyTypeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DisablePolicyTypeError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::AccessDenied(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::InvalidInput(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::PolicyChangesInProgress(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::PolicyTypeNotEnabled(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::RootNotFound(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::Service(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::TooManyRequests(ref cause) => write!(f, "{}", cause),
DisablePolicyTypeError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DisablePolicyTypeError {}
/// Errors returned by EnableAWSServiceAccess
#[derive(Debug, PartialEq)]
pub enum EnableAWSServiceAccessError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl EnableAWSServiceAccessError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<EnableAWSServiceAccessError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
EnableAWSServiceAccessError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(EnableAWSServiceAccessError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
EnableAWSServiceAccessError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(EnableAWSServiceAccessError::ConstraintViolation(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(EnableAWSServiceAccessError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(EnableAWSServiceAccessError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(EnableAWSServiceAccessError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
EnableAWSServiceAccessError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for EnableAWSServiceAccessError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
EnableAWSServiceAccessError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
EnableAWSServiceAccessError::AccessDenied(ref cause) => write!(f, "{}", cause),
EnableAWSServiceAccessError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
EnableAWSServiceAccessError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
EnableAWSServiceAccessError::InvalidInput(ref cause) => write!(f, "{}", cause),
EnableAWSServiceAccessError::Service(ref cause) => write!(f, "{}", cause),
EnableAWSServiceAccessError::TooManyRequests(ref cause) => write!(f, "{}", cause),
EnableAWSServiceAccessError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for EnableAWSServiceAccessError {}
/// Errors returned by EnableAllFeatures
#[derive(Debug, PartialEq)]
pub enum EnableAllFeaturesError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>The requested operation would violate the constraint identified in the reason code.</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation:</p> </note> <ul> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. Note that deleted and closed accounts still count toward your limit.</p> <important> <p>If you get this exception immediately after creating the organization, wait one hour and try again. If after an hour it continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>ALREADY</em>IN<em>AN</em>ORGANIZATION: The handshake request is invalid because the invited account is already a member of an organization.</p> </li> <li> <p>HANDSHAKE<em>RATE</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>INVITE</em>DISABLED<em>DURING</em>ENABLE<em>ALL</em>FEATURES: You can't issue new invitations to join an organization while it's in the process of enabling all features. You can resume inviting accounts after you finalize the process when all accounts have agreed to the change.</p> </li> <li> <p>ORGANIZATION<em>ALREADY</em>HAS<em>ALL</em>FEATURES: The handshake request is invalid because the organization has already enabled all features.</p> </li> <li> <p>ORGANIZATION<em>IS</em>ALREADY<em>PENDING</em>ALL<em>FEATURES</em>MIGRATION: The handshake request is invalid because the organization has already started the process to enable all features.</p> </li> <li> <p>ORGANIZATION<em>FROM</em>DIFFERENT<em>SELLER</em>OF<em>RECORD: The request failed because the account is from a different marketplace than the accounts in the organization. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be from the same marketplace.</p> </li> <li> <p>ORGANIZATION</em>MEMBERSHIP<em>CHANGE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to change the membership of an account too quickly after its previous change.</p> </li> <li> <p>PAYMENT<em>INSTRUMENT</em>REQUIRED: You can't complete the operation with an account that doesn't have a payment instrument, such as a credit card, associated with it.</p> </li> </ul></p>
HandshakeConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl EnableAllFeaturesError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<EnableAllFeaturesError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(EnableAllFeaturesError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(EnableAllFeaturesError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(EnableAllFeaturesError::ConcurrentModification(
err.msg,
))
}
"HandshakeConstraintViolationException" => {
return RusotoError::Service(
EnableAllFeaturesError::HandshakeConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(EnableAllFeaturesError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(EnableAllFeaturesError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(EnableAllFeaturesError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for EnableAllFeaturesError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
EnableAllFeaturesError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
EnableAllFeaturesError::AccessDenied(ref cause) => write!(f, "{}", cause),
EnableAllFeaturesError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
EnableAllFeaturesError::HandshakeConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
EnableAllFeaturesError::InvalidInput(ref cause) => write!(f, "{}", cause),
EnableAllFeaturesError::Service(ref cause) => write!(f, "{}", cause),
EnableAllFeaturesError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for EnableAllFeaturesError {}
/// Errors returned by EnablePolicyType
#[derive(Debug, PartialEq)]
pub enum EnablePolicyTypeError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>Changes to the effective policy are in progress, and its contents can't be returned. Try the operation again later. </p>
PolicyChangesInProgress(String),
/// <p>The specified policy type is already enabled in the specified root.</p>
PolicyTypeAlreadyEnabled(String),
/// <p>You can't use the specified policy type with the feature set currently enabled for this organization. For example, you can enable SCPs only after you enable all features in the organization. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html#enable_policies_on_root">Managing AWS Organizations Policies</a>in the <i>AWS Organizations User Guide.</i> </p>
PolicyTypeNotAvailableForOrganization(String),
/// <p>We can't find a root with the <code>RootId</code> that you specified.</p>
RootNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl EnablePolicyTypeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<EnablePolicyTypeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(EnablePolicyTypeError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(EnablePolicyTypeError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(EnablePolicyTypeError::ConcurrentModification(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(EnablePolicyTypeError::ConstraintViolation(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(EnablePolicyTypeError::InvalidInput(err.msg))
}
"PolicyChangesInProgressException" => {
return RusotoError::Service(EnablePolicyTypeError::PolicyChangesInProgress(
err.msg,
))
}
"PolicyTypeAlreadyEnabledException" => {
return RusotoError::Service(EnablePolicyTypeError::PolicyTypeAlreadyEnabled(
err.msg,
))
}
"PolicyTypeNotAvailableForOrganizationException" => {
return RusotoError::Service(
EnablePolicyTypeError::PolicyTypeNotAvailableForOrganization(err.msg),
)
}
"RootNotFoundException" => {
return RusotoError::Service(EnablePolicyTypeError::RootNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(EnablePolicyTypeError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(EnablePolicyTypeError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(EnablePolicyTypeError::UnsupportedAPIEndpoint(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for EnablePolicyTypeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
EnablePolicyTypeError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::AccessDenied(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::InvalidInput(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::PolicyChangesInProgress(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::PolicyTypeAlreadyEnabled(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::PolicyTypeNotAvailableForOrganization(ref cause) => {
write!(f, "{}", cause)
}
EnablePolicyTypeError::RootNotFound(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::Service(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::TooManyRequests(ref cause) => write!(f, "{}", cause),
EnablePolicyTypeError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for EnablePolicyTypeError {}
/// Errors returned by InviteAccountToOrganization
#[derive(Debug, PartialEq)]
pub enum InviteAccountToOrganizationError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>You can't invite an existing account to your organization until you verify that you own the email address associated with the management account. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_create.html#about-email-verification">Email Address Verification</a> in the <i>AWS Organizations User Guide.</i> </p>
AccountOwnerNotVerified(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>A handshake with the same action and target already exists. For example, if you invited an account to join your organization, the invited account might already have a pending invitation from this organization. If you intend to resend an invitation to an account, ensure that existing handshakes that might be considered duplicates are canceled or declined.</p>
DuplicateHandshake(String),
/// <p>AWS Organizations couldn't perform the operation because your organization hasn't finished initializing. This can take up to an hour. Try again later. If after one hour you continue to receive this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p>
FinalizingOrganization(String),
/// <p><p>The requested operation would violate the constraint identified in the reason code.</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation:</p> </note> <ul> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. Note that deleted and closed accounts still count toward your limit.</p> <important> <p>If you get this exception immediately after creating the organization, wait one hour and try again. If after an hour it continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>ALREADY</em>IN<em>AN</em>ORGANIZATION: The handshake request is invalid because the invited account is already a member of an organization.</p> </li> <li> <p>HANDSHAKE<em>RATE</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>INVITE</em>DISABLED<em>DURING</em>ENABLE<em>ALL</em>FEATURES: You can't issue new invitations to join an organization while it's in the process of enabling all features. You can resume inviting accounts after you finalize the process when all accounts have agreed to the change.</p> </li> <li> <p>ORGANIZATION<em>ALREADY</em>HAS<em>ALL</em>FEATURES: The handshake request is invalid because the organization has already enabled all features.</p> </li> <li> <p>ORGANIZATION<em>IS</em>ALREADY<em>PENDING</em>ALL<em>FEATURES</em>MIGRATION: The handshake request is invalid because the organization has already started the process to enable all features.</p> </li> <li> <p>ORGANIZATION<em>FROM</em>DIFFERENT<em>SELLER</em>OF<em>RECORD: The request failed because the account is from a different marketplace than the accounts in the organization. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be from the same marketplace.</p> </li> <li> <p>ORGANIZATION</em>MEMBERSHIP<em>CHANGE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to change the membership of an account too quickly after its previous change.</p> </li> <li> <p>PAYMENT<em>INSTRUMENT</em>REQUIRED: You can't complete the operation with an account that doesn't have a payment instrument, such as a credit card, associated with it.</p> </li> </ul></p>
HandshakeConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl InviteAccountToOrganizationError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<InviteAccountToOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
InviteAccountToOrganizationError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(InviteAccountToOrganizationError::AccessDenied(
err.msg,
))
}
"AccountOwnerNotVerifiedException" => {
return RusotoError::Service(
InviteAccountToOrganizationError::AccountOwnerNotVerified(err.msg),
)
}
"ConcurrentModificationException" => {
return RusotoError::Service(
InviteAccountToOrganizationError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(
InviteAccountToOrganizationError::ConstraintViolation(err.msg),
)
}
"DuplicateHandshakeException" => {
return RusotoError::Service(
InviteAccountToOrganizationError::DuplicateHandshake(err.msg),
)
}
"FinalizingOrganizationException" => {
return RusotoError::Service(
InviteAccountToOrganizationError::FinalizingOrganization(err.msg),
)
}
"HandshakeConstraintViolationException" => {
return RusotoError::Service(
InviteAccountToOrganizationError::HandshakeConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(InviteAccountToOrganizationError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(InviteAccountToOrganizationError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(InviteAccountToOrganizationError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for InviteAccountToOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
InviteAccountToOrganizationError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
InviteAccountToOrganizationError::AccessDenied(ref cause) => write!(f, "{}", cause),
InviteAccountToOrganizationError::AccountOwnerNotVerified(ref cause) => {
write!(f, "{}", cause)
}
InviteAccountToOrganizationError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
InviteAccountToOrganizationError::ConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
InviteAccountToOrganizationError::DuplicateHandshake(ref cause) => {
write!(f, "{}", cause)
}
InviteAccountToOrganizationError::FinalizingOrganization(ref cause) => {
write!(f, "{}", cause)
}
InviteAccountToOrganizationError::HandshakeConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
InviteAccountToOrganizationError::InvalidInput(ref cause) => write!(f, "{}", cause),
InviteAccountToOrganizationError::Service(ref cause) => write!(f, "{}", cause),
InviteAccountToOrganizationError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for InviteAccountToOrganizationError {}
/// Errors returned by LeaveOrganization
#[derive(Debug, PartialEq)]
pub enum LeaveOrganizationError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p> We can't find an AWS account with the <code>AccountId</code> that you specified, or the account whose credentials you used to make this request isn't a member of an organization.</p>
AccountNotFound(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>You can't remove a management account from an organization. If you want the management account to become a member account in another organization, you must first delete the current organization of the management account.</p>
MasterCannotLeaveOrganization(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl LeaveOrganizationError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<LeaveOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(LeaveOrganizationError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(LeaveOrganizationError::AccessDenied(err.msg))
}
"AccountNotFoundException" => {
return RusotoError::Service(LeaveOrganizationError::AccountNotFound(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(LeaveOrganizationError::ConcurrentModification(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(LeaveOrganizationError::ConstraintViolation(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(LeaveOrganizationError::InvalidInput(err.msg))
}
"MasterCannotLeaveOrganizationException" => {
return RusotoError::Service(
LeaveOrganizationError::MasterCannotLeaveOrganization(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(LeaveOrganizationError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(LeaveOrganizationError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for LeaveOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
LeaveOrganizationError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
LeaveOrganizationError::AccessDenied(ref cause) => write!(f, "{}", cause),
LeaveOrganizationError::AccountNotFound(ref cause) => write!(f, "{}", cause),
LeaveOrganizationError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
LeaveOrganizationError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
LeaveOrganizationError::InvalidInput(ref cause) => write!(f, "{}", cause),
LeaveOrganizationError::MasterCannotLeaveOrganization(ref cause) => {
write!(f, "{}", cause)
}
LeaveOrganizationError::Service(ref cause) => write!(f, "{}", cause),
LeaveOrganizationError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for LeaveOrganizationError {}
/// Errors returned by ListAWSServiceAccessForOrganization
#[derive(Debug, PartialEq)]
pub enum ListAWSServiceAccessForOrganizationError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl ListAWSServiceAccessForOrganizationError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<ListAWSServiceAccessForOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListAWSServiceAccessForOrganizationError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(
ListAWSServiceAccessForOrganizationError::AccessDenied(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(
ListAWSServiceAccessForOrganizationError::ConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(
ListAWSServiceAccessForOrganizationError::InvalidInput(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(ListAWSServiceAccessForOrganizationError::Service(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(
ListAWSServiceAccessForOrganizationError::TooManyRequests(err.msg),
)
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
ListAWSServiceAccessForOrganizationError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListAWSServiceAccessForOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListAWSServiceAccessForOrganizationError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListAWSServiceAccessForOrganizationError::AccessDenied(ref cause) => {
write!(f, "{}", cause)
}
ListAWSServiceAccessForOrganizationError::ConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
ListAWSServiceAccessForOrganizationError::InvalidInput(ref cause) => {
write!(f, "{}", cause)
}
ListAWSServiceAccessForOrganizationError::Service(ref cause) => write!(f, "{}", cause),
ListAWSServiceAccessForOrganizationError::TooManyRequests(ref cause) => {
write!(f, "{}", cause)
}
ListAWSServiceAccessForOrganizationError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for ListAWSServiceAccessForOrganizationError {}
/// Errors returned by ListAccounts
#[derive(Debug, PartialEq)]
pub enum ListAccountsError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListAccountsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListAccountsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(ListAccountsError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(ListAccountsError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListAccountsError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListAccountsError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListAccountsError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListAccountsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListAccountsError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
ListAccountsError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListAccountsError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListAccountsError::Service(ref cause) => write!(f, "{}", cause),
ListAccountsError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListAccountsError {}
/// Errors returned by ListAccountsForParent
#[derive(Debug, PartialEq)]
pub enum ListAccountsForParentError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find a root or OU with the <code>ParentId</code> that you specified.</p>
ParentNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListAccountsForParentError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListAccountsForParentError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListAccountsForParentError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(ListAccountsForParentError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListAccountsForParentError::InvalidInput(err.msg))
}
"ParentNotFoundException" => {
return RusotoError::Service(ListAccountsForParentError::ParentNotFound(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(ListAccountsForParentError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListAccountsForParentError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListAccountsForParentError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListAccountsForParentError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListAccountsForParentError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListAccountsForParentError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListAccountsForParentError::ParentNotFound(ref cause) => write!(f, "{}", cause),
ListAccountsForParentError::Service(ref cause) => write!(f, "{}", cause),
ListAccountsForParentError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListAccountsForParentError {}
/// Errors returned by ListChildren
#[derive(Debug, PartialEq)]
pub enum ListChildrenError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find a root or OU with the <code>ParentId</code> that you specified.</p>
ParentNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListChildrenError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListChildrenError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(ListChildrenError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(ListChildrenError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListChildrenError::InvalidInput(err.msg))
}
"ParentNotFoundException" => {
return RusotoError::Service(ListChildrenError::ParentNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListChildrenError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListChildrenError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListChildrenError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListChildrenError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
ListChildrenError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListChildrenError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListChildrenError::ParentNotFound(ref cause) => write!(f, "{}", cause),
ListChildrenError::Service(ref cause) => write!(f, "{}", cause),
ListChildrenError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListChildrenError {}
/// Errors returned by ListCreateAccountStatus
#[derive(Debug, PartialEq)]
pub enum ListCreateAccountStatusError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl ListCreateAccountStatusError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListCreateAccountStatusError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListCreateAccountStatusError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(ListCreateAccountStatusError::AccessDenied(
err.msg,
))
}
"InvalidInputException" => {
return RusotoError::Service(ListCreateAccountStatusError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(ListCreateAccountStatusError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListCreateAccountStatusError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
ListCreateAccountStatusError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListCreateAccountStatusError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListCreateAccountStatusError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListCreateAccountStatusError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListCreateAccountStatusError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListCreateAccountStatusError::Service(ref cause) => write!(f, "{}", cause),
ListCreateAccountStatusError::TooManyRequests(ref cause) => write!(f, "{}", cause),
ListCreateAccountStatusError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for ListCreateAccountStatusError {}
/// Errors returned by ListDelegatedAdministrators
#[derive(Debug, PartialEq)]
pub enum ListDelegatedAdministratorsError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl ListDelegatedAdministratorsError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<ListDelegatedAdministratorsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListDelegatedAdministratorsError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(ListDelegatedAdministratorsError::AccessDenied(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(
ListDelegatedAdministratorsError::ConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(ListDelegatedAdministratorsError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(ListDelegatedAdministratorsError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListDelegatedAdministratorsError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
ListDelegatedAdministratorsError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListDelegatedAdministratorsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListDelegatedAdministratorsError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListDelegatedAdministratorsError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListDelegatedAdministratorsError::ConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
ListDelegatedAdministratorsError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListDelegatedAdministratorsError::Service(ref cause) => write!(f, "{}", cause),
ListDelegatedAdministratorsError::TooManyRequests(ref cause) => write!(f, "{}", cause),
ListDelegatedAdministratorsError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for ListDelegatedAdministratorsError {}
/// Errors returned by ListDelegatedServicesForAccount
#[derive(Debug, PartialEq)]
pub enum ListDelegatedServicesForAccountError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p> We can't find an AWS account with the <code>AccountId</code> that you specified, or the account whose credentials you used to make this request isn't a member of an organization.</p>
AccountNotFound(String),
/// <p>The specified account is not a delegated administrator for this AWS service. </p>
AccountNotRegistered(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl ListDelegatedServicesForAccountError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<ListDelegatedServicesForAccountError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::AccessDenied(err.msg),
)
}
"AccountNotFoundException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::AccountNotFound(err.msg),
)
}
"AccountNotRegisteredException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::AccountNotRegistered(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::ConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::InvalidInput(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(ListDelegatedServicesForAccountError::Service(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::TooManyRequests(err.msg),
)
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
ListDelegatedServicesForAccountError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListDelegatedServicesForAccountError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListDelegatedServicesForAccountError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListDelegatedServicesForAccountError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListDelegatedServicesForAccountError::AccountNotFound(ref cause) => {
write!(f, "{}", cause)
}
ListDelegatedServicesForAccountError::AccountNotRegistered(ref cause) => {
write!(f, "{}", cause)
}
ListDelegatedServicesForAccountError::ConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
ListDelegatedServicesForAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListDelegatedServicesForAccountError::Service(ref cause) => write!(f, "{}", cause),
ListDelegatedServicesForAccountError::TooManyRequests(ref cause) => {
write!(f, "{}", cause)
}
ListDelegatedServicesForAccountError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for ListDelegatedServicesForAccountError {}
/// Errors returned by ListHandshakesForAccount
#[derive(Debug, PartialEq)]
pub enum ListHandshakesForAccountError {
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListHandshakesForAccountError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListHandshakesForAccountError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AccessDeniedException" => {
return RusotoError::Service(ListHandshakesForAccountError::AccessDenied(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
ListHandshakesForAccountError::ConcurrentModification(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(ListHandshakesForAccountError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(ListHandshakesForAccountError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListHandshakesForAccountError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListHandshakesForAccountError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListHandshakesForAccountError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListHandshakesForAccountError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
ListHandshakesForAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListHandshakesForAccountError::Service(ref cause) => write!(f, "{}", cause),
ListHandshakesForAccountError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListHandshakesForAccountError {}
/// Errors returned by ListHandshakesForOrganization
#[derive(Debug, PartialEq)]
pub enum ListHandshakesForOrganizationError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListHandshakesForOrganizationError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<ListHandshakesForOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListHandshakesForOrganizationError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(ListHandshakesForOrganizationError::AccessDenied(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
ListHandshakesForOrganizationError::ConcurrentModification(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(ListHandshakesForOrganizationError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(ListHandshakesForOrganizationError::Service(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(
ListHandshakesForOrganizationError::TooManyRequests(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListHandshakesForOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListHandshakesForOrganizationError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListHandshakesForOrganizationError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListHandshakesForOrganizationError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
ListHandshakesForOrganizationError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListHandshakesForOrganizationError::Service(ref cause) => write!(f, "{}", cause),
ListHandshakesForOrganizationError::TooManyRequests(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for ListHandshakesForOrganizationError {}
/// Errors returned by ListOrganizationalUnitsForParent
#[derive(Debug, PartialEq)]
pub enum ListOrganizationalUnitsForParentError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find a root or OU with the <code>ParentId</code> that you specified.</p>
ParentNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListOrganizationalUnitsForParentError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<ListOrganizationalUnitsForParentError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListOrganizationalUnitsForParentError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(
ListOrganizationalUnitsForParentError::AccessDenied(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(
ListOrganizationalUnitsForParentError::InvalidInput(err.msg),
)
}
"ParentNotFoundException" => {
return RusotoError::Service(
ListOrganizationalUnitsForParentError::ParentNotFound(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(ListOrganizationalUnitsForParentError::Service(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(
ListOrganizationalUnitsForParentError::TooManyRequests(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListOrganizationalUnitsForParentError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListOrganizationalUnitsForParentError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListOrganizationalUnitsForParentError::AccessDenied(ref cause) => {
write!(f, "{}", cause)
}
ListOrganizationalUnitsForParentError::InvalidInput(ref cause) => {
write!(f, "{}", cause)
}
ListOrganizationalUnitsForParentError::ParentNotFound(ref cause) => {
write!(f, "{}", cause)
}
ListOrganizationalUnitsForParentError::Service(ref cause) => write!(f, "{}", cause),
ListOrganizationalUnitsForParentError::TooManyRequests(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for ListOrganizationalUnitsForParentError {}
/// Errors returned by ListParents
#[derive(Debug, PartialEq)]
pub enum ListParentsError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>We can't find an organizational unit (OU) or AWS account with the <code>ChildId</code> that you specified.</p>
ChildNotFound(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListParentsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListParentsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(ListParentsError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(ListParentsError::AccessDenied(err.msg))
}
"ChildNotFoundException" => {
return RusotoError::Service(ListParentsError::ChildNotFound(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListParentsError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListParentsError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListParentsError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListParentsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListParentsError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
ListParentsError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListParentsError::ChildNotFound(ref cause) => write!(f, "{}", cause),
ListParentsError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListParentsError::Service(ref cause) => write!(f, "{}", cause),
ListParentsError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListParentsError {}
/// Errors returned by ListPolicies
#[derive(Debug, PartialEq)]
pub enum ListPoliciesError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl ListPoliciesError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListPoliciesError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(ListPoliciesError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(ListPoliciesError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListPoliciesError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListPoliciesError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListPoliciesError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(ListPoliciesError::UnsupportedAPIEndpoint(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListPoliciesError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListPoliciesError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
ListPoliciesError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListPoliciesError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListPoliciesError::Service(ref cause) => write!(f, "{}", cause),
ListPoliciesError::TooManyRequests(ref cause) => write!(f, "{}", cause),
ListPoliciesError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListPoliciesError {}
/// Errors returned by ListPoliciesForTarget
#[derive(Debug, PartialEq)]
pub enum ListPoliciesForTargetError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a root, OU, account, or policy with the <code>TargetId</code> that you specified.</p>
TargetNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl ListPoliciesForTargetError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListPoliciesForTargetError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListPoliciesForTargetError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(ListPoliciesForTargetError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListPoliciesForTargetError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListPoliciesForTargetError::Service(err.msg))
}
"TargetNotFoundException" => {
return RusotoError::Service(ListPoliciesForTargetError::TargetNotFound(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListPoliciesForTargetError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
ListPoliciesForTargetError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListPoliciesForTargetError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListPoliciesForTargetError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListPoliciesForTargetError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListPoliciesForTargetError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListPoliciesForTargetError::Service(ref cause) => write!(f, "{}", cause),
ListPoliciesForTargetError::TargetNotFound(ref cause) => write!(f, "{}", cause),
ListPoliciesForTargetError::TooManyRequests(ref cause) => write!(f, "{}", cause),
ListPoliciesForTargetError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListPoliciesForTargetError {}
/// Errors returned by ListRoots
#[derive(Debug, PartialEq)]
pub enum ListRootsError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListRootsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListRootsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(ListRootsError::AWSOrganizationsNotInUse(err.msg))
}
"AccessDeniedException" => {
return RusotoError::Service(ListRootsError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListRootsError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListRootsError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListRootsError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListRootsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListRootsError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
ListRootsError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListRootsError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListRootsError::Service(ref cause) => write!(f, "{}", cause),
ListRootsError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListRootsError {}
/// Errors returned by ListTagsForResource
#[derive(Debug, PartialEq)]
pub enum ListTagsForResourceError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a root, OU, account, or policy with the <code>TargetId</code> that you specified.</p>
TargetNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl ListTagsForResourceError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListTagsForResourceError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListTagsForResourceError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(ListTagsForResourceError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListTagsForResourceError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListTagsForResourceError::Service(err.msg))
}
"TargetNotFoundException" => {
return RusotoError::Service(ListTagsForResourceError::TargetNotFound(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListTagsForResourceError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListTagsForResourceError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListTagsForResourceError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
ListTagsForResourceError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListTagsForResourceError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListTagsForResourceError::Service(ref cause) => write!(f, "{}", cause),
ListTagsForResourceError::TargetNotFound(ref cause) => write!(f, "{}", cause),
ListTagsForResourceError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListTagsForResourceError {}
/// Errors returned by ListTargetsForPolicy
#[derive(Debug, PartialEq)]
pub enum ListTargetsForPolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find a policy with the <code>PolicyId</code> that you specified.</p>
PolicyNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl ListTargetsForPolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListTargetsForPolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
ListTargetsForPolicyError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(ListTargetsForPolicyError::AccessDenied(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(ListTargetsForPolicyError::InvalidInput(err.msg))
}
"PolicyNotFoundException" => {
return RusotoError::Service(ListTargetsForPolicyError::PolicyNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(ListTargetsForPolicyError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(ListTargetsForPolicyError::TooManyRequests(
err.msg,
))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(ListTargetsForPolicyError::UnsupportedAPIEndpoint(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListTargetsForPolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListTargetsForPolicyError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
ListTargetsForPolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
ListTargetsForPolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
ListTargetsForPolicyError::PolicyNotFound(ref cause) => write!(f, "{}", cause),
ListTargetsForPolicyError::Service(ref cause) => write!(f, "{}", cause),
ListTargetsForPolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
ListTargetsForPolicyError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListTargetsForPolicyError {}
/// Errors returned by MoveAccount
#[derive(Debug, PartialEq)]
pub enum MoveAccountError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p> We can't find an AWS account with the <code>AccountId</code> that you specified, or the account whose credentials you used to make this request isn't a member of an organization.</p>
AccountNotFound(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p>We can't find the destination container (a root or OU) with the <code>ParentId</code> that you specified.</p>
DestinationParentNotFound(String),
/// <p>That account is already present in the specified destination.</p>
DuplicateAccount(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a source root or OU with the <code>ParentId</code> that you specified.</p>
SourceParentNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl MoveAccountError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<MoveAccountError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(MoveAccountError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(MoveAccountError::AccessDenied(err.msg))
}
"AccountNotFoundException" => {
return RusotoError::Service(MoveAccountError::AccountNotFound(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(MoveAccountError::ConcurrentModification(err.msg))
}
"DestinationParentNotFoundException" => {
return RusotoError::Service(MoveAccountError::DestinationParentNotFound(
err.msg,
))
}
"DuplicateAccountException" => {
return RusotoError::Service(MoveAccountError::DuplicateAccount(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(MoveAccountError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(MoveAccountError::Service(err.msg))
}
"SourceParentNotFoundException" => {
return RusotoError::Service(MoveAccountError::SourceParentNotFound(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(MoveAccountError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for MoveAccountError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
MoveAccountError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
MoveAccountError::AccessDenied(ref cause) => write!(f, "{}", cause),
MoveAccountError::AccountNotFound(ref cause) => write!(f, "{}", cause),
MoveAccountError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
MoveAccountError::DestinationParentNotFound(ref cause) => write!(f, "{}", cause),
MoveAccountError::DuplicateAccount(ref cause) => write!(f, "{}", cause),
MoveAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
MoveAccountError::Service(ref cause) => write!(f, "{}", cause),
MoveAccountError::SourceParentNotFound(ref cause) => write!(f, "{}", cause),
MoveAccountError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for MoveAccountError {}
/// Errors returned by RegisterDelegatedAdministrator
#[derive(Debug, PartialEq)]
pub enum RegisterDelegatedAdministratorError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The specified account is already a delegated administrator for this AWS service.</p>
AccountAlreadyRegistered(String),
/// <p> We can't find an AWS account with the <code>AccountId</code> that you specified, or the account whose credentials you used to make this request isn't a member of an organization.</p>
AccountNotFound(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl RegisterDelegatedAdministratorError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<RegisterDelegatedAdministratorError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
RegisterDelegatedAdministratorError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(RegisterDelegatedAdministratorError::AccessDenied(
err.msg,
))
}
"AccountAlreadyRegisteredException" => {
return RusotoError::Service(
RegisterDelegatedAdministratorError::AccountAlreadyRegistered(err.msg),
)
}
"AccountNotFoundException" => {
return RusotoError::Service(
RegisterDelegatedAdministratorError::AccountNotFound(err.msg),
)
}
"ConcurrentModificationException" => {
return RusotoError::Service(
RegisterDelegatedAdministratorError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(
RegisterDelegatedAdministratorError::ConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(RegisterDelegatedAdministratorError::InvalidInput(
err.msg,
))
}
"ServiceException" => {
return RusotoError::Service(RegisterDelegatedAdministratorError::Service(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(
RegisterDelegatedAdministratorError::TooManyRequests(err.msg),
)
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(
RegisterDelegatedAdministratorError::UnsupportedAPIEndpoint(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for RegisterDelegatedAdministratorError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
RegisterDelegatedAdministratorError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
RegisterDelegatedAdministratorError::AccessDenied(ref cause) => write!(f, "{}", cause),
RegisterDelegatedAdministratorError::AccountAlreadyRegistered(ref cause) => {
write!(f, "{}", cause)
}
RegisterDelegatedAdministratorError::AccountNotFound(ref cause) => {
write!(f, "{}", cause)
}
RegisterDelegatedAdministratorError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
RegisterDelegatedAdministratorError::ConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
RegisterDelegatedAdministratorError::InvalidInput(ref cause) => write!(f, "{}", cause),
RegisterDelegatedAdministratorError::Service(ref cause) => write!(f, "{}", cause),
RegisterDelegatedAdministratorError::TooManyRequests(ref cause) => {
write!(f, "{}", cause)
}
RegisterDelegatedAdministratorError::UnsupportedAPIEndpoint(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for RegisterDelegatedAdministratorError {}
/// Errors returned by RemoveAccountFromOrganization
#[derive(Debug, PartialEq)]
pub enum RemoveAccountFromOrganizationError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p> We can't find an AWS account with the <code>AccountId</code> that you specified, or the account whose credentials you used to make this request isn't a member of an organization.</p>
AccountNotFound(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>You can't remove a management account from an organization. If you want the management account to become a member account in another organization, you must first delete the current organization of the management account.</p>
MasterCannotLeaveOrganization(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl RemoveAccountFromOrganizationError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<RemoveAccountFromOrganizationError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
RemoveAccountFromOrganizationError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(RemoveAccountFromOrganizationError::AccessDenied(
err.msg,
))
}
"AccountNotFoundException" => {
return RusotoError::Service(
RemoveAccountFromOrganizationError::AccountNotFound(err.msg),
)
}
"ConcurrentModificationException" => {
return RusotoError::Service(
RemoveAccountFromOrganizationError::ConcurrentModification(err.msg),
)
}
"ConstraintViolationException" => {
return RusotoError::Service(
RemoveAccountFromOrganizationError::ConstraintViolation(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(RemoveAccountFromOrganizationError::InvalidInput(
err.msg,
))
}
"MasterCannotLeaveOrganizationException" => {
return RusotoError::Service(
RemoveAccountFromOrganizationError::MasterCannotLeaveOrganization(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(RemoveAccountFromOrganizationError::Service(
err.msg,
))
}
"TooManyRequestsException" => {
return RusotoError::Service(
RemoveAccountFromOrganizationError::TooManyRequests(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for RemoveAccountFromOrganizationError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
RemoveAccountFromOrganizationError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
RemoveAccountFromOrganizationError::AccessDenied(ref cause) => write!(f, "{}", cause),
RemoveAccountFromOrganizationError::AccountNotFound(ref cause) => {
write!(f, "{}", cause)
}
RemoveAccountFromOrganizationError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
RemoveAccountFromOrganizationError::ConstraintViolation(ref cause) => {
write!(f, "{}", cause)
}
RemoveAccountFromOrganizationError::InvalidInput(ref cause) => write!(f, "{}", cause),
RemoveAccountFromOrganizationError::MasterCannotLeaveOrganization(ref cause) => {
write!(f, "{}", cause)
}
RemoveAccountFromOrganizationError::Service(ref cause) => write!(f, "{}", cause),
RemoveAccountFromOrganizationError::TooManyRequests(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for RemoveAccountFromOrganizationError {}
/// Errors returned by TagResource
#[derive(Debug, PartialEq)]
pub enum TagResourceError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a root, OU, account, or policy with the <code>TargetId</code> that you specified.</p>
TargetNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl TagResourceError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<TagResourceError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(TagResourceError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(TagResourceError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(TagResourceError::ConcurrentModification(err.msg))
}
"ConstraintViolationException" => {
return RusotoError::Service(TagResourceError::ConstraintViolation(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(TagResourceError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(TagResourceError::Service(err.msg))
}
"TargetNotFoundException" => {
return RusotoError::Service(TagResourceError::TargetNotFound(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(TagResourceError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for TagResourceError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
TagResourceError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
TagResourceError::AccessDenied(ref cause) => write!(f, "{}", cause),
TagResourceError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
TagResourceError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
TagResourceError::InvalidInput(ref cause) => write!(f, "{}", cause),
TagResourceError::Service(ref cause) => write!(f, "{}", cause),
TagResourceError::TargetNotFound(ref cause) => write!(f, "{}", cause),
TagResourceError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for TagResourceError {}
/// Errors returned by UntagResource
#[derive(Debug, PartialEq)]
pub enum UntagResourceError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>We can't find a root, OU, account, or policy with the <code>TargetId</code> that you specified.</p>
TargetNotFound(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl UntagResourceError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UntagResourceError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(UntagResourceError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(UntagResourceError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(UntagResourceError::ConcurrentModification(
err.msg,
))
}
"ConstraintViolationException" => {
return RusotoError::Service(UntagResourceError::ConstraintViolation(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(UntagResourceError::InvalidInput(err.msg))
}
"ServiceException" => {
return RusotoError::Service(UntagResourceError::Service(err.msg))
}
"TargetNotFoundException" => {
return RusotoError::Service(UntagResourceError::TargetNotFound(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(UntagResourceError::TooManyRequests(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for UntagResourceError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
UntagResourceError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
UntagResourceError::AccessDenied(ref cause) => write!(f, "{}", cause),
UntagResourceError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
UntagResourceError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
UntagResourceError::InvalidInput(ref cause) => write!(f, "{}", cause),
UntagResourceError::Service(ref cause) => write!(f, "{}", cause),
UntagResourceError::TargetNotFound(ref cause) => write!(f, "{}", cause),
UntagResourceError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for UntagResourceError {}
/// Errors returned by UpdateOrganizationalUnit
#[derive(Debug, PartialEq)]
pub enum UpdateOrganizationalUnitError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p>An OU with the same name already exists.</p>
DuplicateOrganizationalUnit(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>We can't find an OU with the <code>OrganizationalUnitId</code> that you specified.</p>
OrganizationalUnitNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
}
impl UpdateOrganizationalUnitError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdateOrganizationalUnitError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(
UpdateOrganizationalUnitError::AWSOrganizationsNotInUse(err.msg),
)
}
"AccessDeniedException" => {
return RusotoError::Service(UpdateOrganizationalUnitError::AccessDenied(
err.msg,
))
}
"ConcurrentModificationException" => {
return RusotoError::Service(
UpdateOrganizationalUnitError::ConcurrentModification(err.msg),
)
}
"DuplicateOrganizationalUnitException" => {
return RusotoError::Service(
UpdateOrganizationalUnitError::DuplicateOrganizationalUnit(err.msg),
)
}
"InvalidInputException" => {
return RusotoError::Service(UpdateOrganizationalUnitError::InvalidInput(
err.msg,
))
}
"OrganizationalUnitNotFoundException" => {
return RusotoError::Service(
UpdateOrganizationalUnitError::OrganizationalUnitNotFound(err.msg),
)
}
"ServiceException" => {
return RusotoError::Service(UpdateOrganizationalUnitError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(UpdateOrganizationalUnitError::TooManyRequests(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for UpdateOrganizationalUnitError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
UpdateOrganizationalUnitError::AWSOrganizationsNotInUse(ref cause) => {
write!(f, "{}", cause)
}
UpdateOrganizationalUnitError::AccessDenied(ref cause) => write!(f, "{}", cause),
UpdateOrganizationalUnitError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
UpdateOrganizationalUnitError::DuplicateOrganizationalUnit(ref cause) => {
write!(f, "{}", cause)
}
UpdateOrganizationalUnitError::InvalidInput(ref cause) => write!(f, "{}", cause),
UpdateOrganizationalUnitError::OrganizationalUnitNotFound(ref cause) => {
write!(f, "{}", cause)
}
UpdateOrganizationalUnitError::Service(ref cause) => write!(f, "{}", cause),
UpdateOrganizationalUnitError::TooManyRequests(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for UpdateOrganizationalUnitError {}
/// Errors returned by UpdatePolicy
#[derive(Debug, PartialEq)]
pub enum UpdatePolicyError {
/// <p>Your account isn't a member of an organization. To make this request, you must use the credentials of an account that belongs to an organization.</p>
AWSOrganizationsNotInUse(String),
/// <p>You don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access Management</a> in the <i>IAM User Guide.</i> </p>
AccessDenied(String),
/// <p>The target of the operation is currently being modified by a different request. Try again later.</p>
ConcurrentModification(String),
/// <p><p>Performing this operation violates a minimum or maximum value limit. For example, attempting to remove the last service control policy (SCP) from an OU or root, inviting or creating too many accounts to the organization, or attaching too many policies to an account, OU, or root. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>ACCOUNT<em>CANNOT</em>LEAVE<em>ORGANIZATION: You attempted to remove the management account from the organization. You can't remove the management account. Instead, after you remove all member accounts, delete the organization itself.</p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>EULA: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first agree to the AWS Customer Agreement. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs</em>manage<em>accounts</em>remove.html#orgs<em>manage</em>accounts<em>remove-from-master">Removing a member account from your organization</a>in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT</em>CANNOT<em>LEAVE</em>WITHOUT<em>PHONE</em>VERIFICATION: You attempted to remove an account from the organization that doesn't yet have enough information to exist as a standalone account. This account requires you to first complete phone verification. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#orgs_manage_accounts_remove-from-master">Removing a member account from your organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>ACCOUNT<em>CREATION</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of accounts that you can create in one day.</p> </li> <li> <p>ACCOUNT<em>NUMBER</em>LIMIT<em>EXCEEDED: You attempted to exceed the limit on the number of accounts in an organization. If you need more accounts, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a> to request an increase in your limit. </p> <p>Or the number of invitations that you tried to send would cause you to exceed the limit of accounts in your organization. Send fewer invitations or contact AWS Support to request an increase in the number of accounts.</p> <note> <p>Deleted and closed accounts still count toward your limit.</p> </note> <important> <p>If you get this exception when running a command immediately after creating the organization, wait one hour and try again. After an hour, if the command continues to fail with this error, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </important> </li> <li> <p>CANNOT</em>REGISTER<em>MASTER</em>AS<em>DELEGATED</em>ADMINISTRATOR: You attempted to register the management account of the organization as a delegated administrator for an AWS service integrated with Organizations. You can designate only a member account as a delegated administrator.</p> </li> <li> <p>CANNOT<em>REMOVE</em>DELEGATED<em>ADMINISTRATOR</em>FROM<em>ORG: You attempted to remove an account that is registered as a delegated administrator for a service integrated with your organization. To complete this operation, you must first deregister this account as a delegated administrator. </p> </li> <li> <p>CREATE</em>ORGANIZATION<em>IN</em>BILLING<em>MODE</em>UNSUPPORTED<em>REGION: To create an organization in the specified region, you must enable all features mode.</p> </li> <li> <p>DELEGATED</em>ADMINISTRATOR<em>EXISTS</em>FOR<em>THIS</em>SERVICE: You attempted to register an AWS account as a delegated administrator for an AWS service that already has a delegated administrator. To complete this operation, you must first deregister any existing delegated administrators for this service.</p> </li> <li> <p>EMAIL<em>VERIFICATION</em>CODE<em>EXPIRED: The email verification code is only valid for a limited period of time. You must resubmit the request and generate a new verfication code.</p> </li> <li> <p>HANDSHAKE</em>RATE<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of handshakes that you can send in one day.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>ADDRESS<em>DOES</em>NOT<em>MATCH</em>MARKETPLACE: To create an account in this organization, you first must migrate the organization's management account to the marketplace that corresponds to the management account's address. For example, accounts with India addresses must be associated with the AISPL marketplace. All accounts in an organization must be associated with the same marketplace.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>BUSINESS</em>LICENSE: Applies only to the AWS Regions in China. To create an organization, the master must have a valid business license. For more information, contact customer support.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>MISSING<em>CONTACT</em>INFO: To complete this operation, you must first provide a valid contact address and phone number for the management account. Then try the operation again.</p> </li> <li> <p>MASTER<em>ACCOUNT</em>NOT<em>GOVCLOUD</em>ENABLED: To complete this operation, the management account must have an associated account in the AWS GovCloud (US-West) Region. For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> </li> <li> <p>MASTER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To create an organization with this management account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MAX<em>DELEGATED</em>ADMINISTRATORS<em>FOR</em>SERVICE<em>LIMIT</em>EXCEEDED: You attempted to register more delegated administrators than allowed for the service principal. </p> </li> <li> <p>MAX<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to exceed the number of policies of a certain type that can be attached to an entity at one time.</p> </li> <li> <p>MAX</em>TAG<em>LIMIT</em>EXCEEDED: You have exceeded the number of tags allowed on this resource. </p> </li> <li> <p>MEMBER<em>ACCOUNT</em>PAYMENT<em>INSTRUMENT</em>REQUIRED: To complete this operation with this member account, you first must associate a valid payment instrument, such as a credit card, with the account. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info">To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>MIN<em>POLICY</em>TYPE<em>ATTACHMENT</em>LIMIT<em>EXCEEDED: You attempted to detach a policy from an entity that would cause the entity to have fewer than the minimum number of policies of a certain type required.</p> </li> <li> <p>ORGANIZATION</em>NOT<em>IN</em>ALL<em>FEATURES</em>MODE: You attempted to perform an operation that requires the organization to be configured to support all features. An organization that supports only consolidated billing features can't perform this operation.</p> </li> <li> <p>OU<em>DEPTH</em>LIMIT<em>EXCEEDED: You attempted to create an OU tree that is too many levels deep.</p> </li> <li> <p>OU</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of OUs that you can have in an organization.</p> </li> <li> <p>POLICY<em>CONTENT</em>LIMIT<em>EXCEEDED: You attempted to create a policy that is larger than the maximum size.</p> </li> <li> <p>POLICY</em>NUMBER<em>LIMIT</em>EXCEEDED: You attempted to exceed the number of policies that you can have in an organization.</p> </li> <li> <p>TAG<em>POLICY</em>VIOLATION: You attempted to create or update a resource with tags that are not compliant with the tag policy requirements for this account.</p> </li> </ul></p>
ConstraintViolation(String),
/// <p>A policy with the same name already exists.</p>
DuplicatePolicy(String),
/// <p><p>The requested operation failed because you provided invalid values for one or more of the request parameters. This exception includes a reason that contains additional information about the violated limit:</p> <note> <p>Some of the reasons in the following list might not be applicable to this specific API or operation.</p> </note> <ul> <li> <p>DUPLICATE<em>TAG</em>KEY: Tag keys must be unique among the tags attached to the same entity.</p> </li> <li> <p>IMMUTABLE<em>POLICY: You specified a policy that is managed by AWS and can't be modified.</p> </li> <li> <p>INPUT</em>REQUIRED: You must include a value for all required parameters.</p> </li> <li> <p>INVALID<em>EMAIL</em>ADDRESS<em>TARGET: You specified an invalid email address for the invited account owner.</p> </li> <li> <p>INVALID</em>ENUM: You specified an invalid value.</p> </li> <li> <p>INVALID<em>ENUM</em>POLICY<em>TYPE: You specified an invalid policy type string.</p> </li> <li> <p>INVALID</em>FULL<em>NAME</em>TARGET: You specified a full name that contains invalid characters.</p> </li> <li> <p>INVALID<em>LIST</em>MEMBER: You provided a list to a parameter that contains at least one invalid value.</p> </li> <li> <p>INVALID<em>PAGINATION</em>TOKEN: Get the value for the <code>NextToken</code> parameter from the response to a previous call of the operation.</p> </li> <li> <p>INVALID<em>PARTY</em>TYPE<em>TARGET: You specified the wrong type of entity (account, organization, or email) as a party.</p> </li> <li> <p>INVALID</em>PATTERN: You provided a value that doesn't match the required pattern.</p> </li> <li> <p>INVALID<em>PATTERN</em>TARGET<em>ID: You specified a policy target ID that doesn't match the required pattern.</p> </li> <li> <p>INVALID</em>ROLE<em>NAME: You provided a role name that isn't valid. A role name can't begin with the reserved prefix <code>AWSServiceRoleFor</code>.</p> </li> <li> <p>INVALID</em>SYNTAX<em>ORGANIZATION</em>ARN: You specified an invalid Amazon Resource Name (ARN) for the organization.</p> </li> <li> <p>INVALID<em>SYNTAX</em>POLICY<em>ID: You specified an invalid policy ID. </p> </li> <li> <p>INVALID</em>SYSTEM<em>TAGS</em>PARAMETER: You specified a tag key that is a system tag. You can’t add, edit, or delete system tag keys because they're reserved for AWS use. System tags don’t count against your tags per resource limit.</p> </li> <li> <p>MAX<em>FILTER</em>LIMIT<em>EXCEEDED: You can specify only one filter parameter for the operation.</p> </li> <li> <p>MAX</em>LENGTH<em>EXCEEDED: You provided a string parameter that is longer than allowed.</p> </li> <li> <p>MAX</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a larger value than allowed.</p> </li> <li> <p>MIN</em>LENGTH<em>EXCEEDED: You provided a string parameter that is shorter than allowed.</p> </li> <li> <p>MIN</em>VALUE<em>EXCEEDED: You provided a numeric parameter that has a smaller value than allowed.</p> </li> <li> <p>MOVING</em>ACCOUNT<em>BETWEEN</em>DIFFERENT<em>ROOTS: You can move an account only between entities in the same root.</p> </li> <li> <p>TARGET</em>NOT<em>SUPPORTED: You can't perform the specified operation on that target entity.</p> </li> <li> <p>UNRECOGNIZED</em>SERVICE_PRINCIPAL: You specified a service principal that isn't recognized.</p> </li> </ul></p>
InvalidInput(String),
/// <p>The provided policy document doesn't meet the requirements of the specified policy type. For example, the syntax might be incorrect. For details about service control policy syntax, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html">Service Control Policy Syntax</a> in the <i>AWS Organizations User Guide.</i> </p>
MalformedPolicyDocument(String),
/// <p>Changes to the effective policy are in progress, and its contents can't be returned. Try the operation again later. </p>
PolicyChangesInProgress(String),
/// <p>We can't find a policy with the <code>PolicyId</code> that you specified.</p>
PolicyNotFound(String),
/// <p>AWS Organizations can't complete your request because of an internal service error. Try again later.</p>
Service(String),
/// <p>You have sent too many requests in too short a period of time. The quota helps protect against denial-of-service attacks. Try again later.</p> <p>For information about quotas that affect AWS Organizations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_limits.html">Quotas for AWS Organizations</a>in the <i>AWS Organizations User Guide.</i> </p>
TooManyRequests(String),
/// <p>This action isn't available in the current AWS Region.</p>
UnsupportedAPIEndpoint(String),
}
impl UpdatePolicyError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdatePolicyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"AWSOrganizationsNotInUseException" => {
return RusotoError::Service(UpdatePolicyError::AWSOrganizationsNotInUse(
err.msg,
))
}
"AccessDeniedException" => {
return RusotoError::Service(UpdatePolicyError::AccessDenied(err.msg))
}
"ConcurrentModificationException" => {
return RusotoError::Service(UpdatePolicyError::ConcurrentModification(err.msg))
}
"ConstraintViolationException" => {
return RusotoError::Service(UpdatePolicyError::ConstraintViolation(err.msg))
}
"DuplicatePolicyException" => {
return RusotoError::Service(UpdatePolicyError::DuplicatePolicy(err.msg))
}
"InvalidInputException" => {
return RusotoError::Service(UpdatePolicyError::InvalidInput(err.msg))
}
"MalformedPolicyDocumentException" => {
return RusotoError::Service(UpdatePolicyError::MalformedPolicyDocument(
err.msg,
))
}
"PolicyChangesInProgressException" => {
return RusotoError::Service(UpdatePolicyError::PolicyChangesInProgress(
err.msg,
))
}
"PolicyNotFoundException" => {
return RusotoError::Service(UpdatePolicyError::PolicyNotFound(err.msg))
}
"ServiceException" => {
return RusotoError::Service(UpdatePolicyError::Service(err.msg))
}
"TooManyRequestsException" => {
return RusotoError::Service(UpdatePolicyError::TooManyRequests(err.msg))
}
"UnsupportedAPIEndpointException" => {
return RusotoError::Service(UpdatePolicyError::UnsupportedAPIEndpoint(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for UpdatePolicyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
UpdatePolicyError::AWSOrganizationsNotInUse(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::AccessDenied(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::ConstraintViolation(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::DuplicatePolicy(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::InvalidInput(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::MalformedPolicyDocument(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::PolicyChangesInProgress(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::PolicyNotFound(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::Service(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::TooManyRequests(ref cause) => write!(f, "{}", cause),
UpdatePolicyError::UnsupportedAPIEndpoint(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for UpdatePolicyError {}
/// Trait representing the capabilities of the Organizations API. Organizations clients implement this trait.
#[async_trait]
pub trait Organizations {
/// <p>Sends a response to the originator of a handshake agreeing to the action proposed by the handshake request.</p> <p>This operation can be called only by the following principals when they also have the relevant IAM permissions:</p> <ul> <li> <p> <b>Invitation to join</b> or <b>Approve all features request</b> handshakes: only a principal from the member account.</p> <p>The user who calls the API for an invitation to join must have the <code>organizations:AcceptHandshake</code> permission. If you enabled all features in the organization, the user must also have the <code>iam:CreateServiceLinkedRole</code> permission so that AWS Organizations can create the required service-linked role named <code>AWSServiceRoleForOrganizations</code>. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integration_services.html#orgs_integration_service-linked-roles">AWS Organizations and Service-Linked Roles</a> in the <i>AWS Organizations User Guide</i>.</p> </li> <li> <p> <b>Enable all features final confirmation</b> handshake: only a principal from the management account.</p> <p>For more information about invitations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_invites.html">Inviting an AWS Account to Join Your Organization</a> in the <i>AWS Organizations User Guide.</i> For more information about requests to enable all features in the organization, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">Enabling All Features in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> </ul> <p>After you accept a handshake, it continues to appear in the results of relevant APIs for only 30 days. After that, it's deleted.</p>
async fn accept_handshake(
&self,
input: AcceptHandshakeRequest,
) -> Result<AcceptHandshakeResponse, RusotoError<AcceptHandshakeError>>;
/// <p>Attaches a policy to a root, an organizational unit (OU), or an individual account. How the policy affects accounts depends on the type of policy. Refer to the <i>AWS Organizations User Guide</i> for information about each policy type:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES_OPT_OUT_POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_backup.html">BACKUP_POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_scp.html">SERVICE_CONTROL_POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_tag-policies.html">TAG_POLICY</a> </p> </li> </ul> <p>This operation can be called only from the organization's management account.</p>
async fn attach_policy(
&self,
input: AttachPolicyRequest,
) -> Result<(), RusotoError<AttachPolicyError>>;
/// <p>Cancels a handshake. Canceling a handshake sets the handshake state to <code>CANCELED</code>.</p> <p>This operation can be called only from the account that originated the handshake. The recipient of the handshake can't cancel it, but can use <a>DeclineHandshake</a> instead. After a handshake is canceled, the recipient can no longer respond to that handshake.</p> <p>After you cancel a handshake, it continues to appear in the results of relevant APIs for only 30 days. After that, it's deleted.</p>
async fn cancel_handshake(
&self,
input: CancelHandshakeRequest,
) -> Result<CancelHandshakeResponse, RusotoError<CancelHandshakeError>>;
/// <p><p>Creates an AWS account that is automatically a member of the organization whose credentials made the request. This is an asynchronous request that AWS performs in the background. Because <code>CreateAccount</code> operates asynchronously, it can return a successful completion message even though account initialization might still be in progress. You might need to wait a few minutes before you can successfully access the account. To check the status of the request, do one of the following:</p> <ul> <li> <p>Use the <code>Id</code> member of the <code>CreateAccountStatus</code> response element from this operation to provide as a parameter to the <a>DescribeCreateAccountStatus</a> operation.</p> </li> <li> <p>Check the AWS CloudTrail log for the <code>CreateAccountResult</code> event. For information on using AWS CloudTrail with AWS Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_security_incident-response.html#orgs_cloudtrail-integration">Logging and monitoring in AWS Organizations</a> in the <i>AWS Organizations User Guide.</i> </p> </li> </ul> <p>The user who calls the API to create an account must have the <code>organizations:CreateAccount</code> permission. If you enabled all features in the organization, AWS Organizations creates the required service-linked role named <code>AWSServiceRoleForOrganizations</code>. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html#orgs_integrate_services-using_slrs">AWS Organizations and Service-Linked Roles</a> in the <i>AWS Organizations User Guide</i>.</p> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>AWS Organizations preconfigures the new member account with a role (named <code>OrganizationAccountAccessRole</code> by default) that grants users in the management account administrator permissions in the new member account. Principals in the management account can assume the role. AWS Organizations clones the company name and address information for the new account from the organization's management account.</p> <p>This operation can be called only from the organization's management account.</p> <p>For more information about creating accounts, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_create.html">Creating an AWS Account in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> <important> <ul> <li> <p>When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required for the account to operate as a standalone account, such as a payment method and signing the end user license agreement (EULA) is <i>not</i> automatically collected. If you must remove an account from your organization later, you can do so only after you provide the missing information. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization as a member account</a> in the <i>AWS Organizations User Guide</i>.</p> </li> <li> <p>If you get an exception that indicates that you exceeded your account limits for the organization, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>If you get an exception that indicates that the operation failed because your organization is still initializing, wait one hour and then try again. If the error persists, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>Using <code>CreateAccount</code> to create multiple temporary accounts isn't recommended. You can only close an account from the Billing and Cost Management Console, and you must be signed in as the root user. For information on the requirements and process for closing an account, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_close.html">Closing an AWS Account</a> in the <i>AWS Organizations User Guide</i>.</p> </li> </ul> </important> <note> <p>When you create a member account with this operation, you can choose whether to create the account with the <b>IAM User and Role Access to Billing Information</b> switch enabled. If you enable it, IAM users and roles that have appropriate permissions can view billing information for the account. If you disable it, only the account root user can access billing information. For information about how to disable this switch for an account, see <a href="https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html">Granting Access to Your Billing Information and Tools</a>.</p> </note></p>
async fn create_account(
&self,
input: CreateAccountRequest,
) -> Result<CreateAccountResponse, RusotoError<CreateAccountError>>;
/// <p><p>This action is available if all of the following are true:</p> <ul> <li> <p>You're authorized to create accounts in the AWS GovCloud (US) Region. For more information on the AWS GovCloud (US) Region, see the <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/welcome.html"> <i>AWS GovCloud User Guide</i>.</a> </p> </li> <li> <p>You already have an account in the AWS GovCloud (US) Region that is paired with a management account of an organization in the commercial Region.</p> </li> <li> <p>You call this action from the management account of your organization in the commercial Region.</p> </li> <li> <p>You have the <code>organizations:CreateGovCloudAccount</code> permission. </p> </li> </ul> <p>AWS Organizations automatically creates the required service-linked role named <code>AWSServiceRoleForOrganizations</code>. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html#orgs_integrate_services-using_slrs">AWS Organizations and Service-Linked Roles</a> in the <i>AWS Organizations User Guide.</i> </p> <p>AWS automatically enables AWS CloudTrail for AWS GovCloud (US) accounts, but you should also do the following:</p> <ul> <li> <p>Verify that AWS CloudTrail is enabled to store logs.</p> </li> <li> <p>Create an S3 bucket for AWS CloudTrail log storage.</p> <p>For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/verifying-cloudtrail.html">Verifying AWS CloudTrail Is Enabled</a> in the <i>AWS GovCloud User Guide</i>. </p> </li> </ul> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission. The tags are attached to the commercial account associated with the GovCloud account, rather than the GovCloud account itself. To add tags to the GovCloud account, call the <a>TagResource</a> operation in the GovCloud Region after the new GovCloud account exists.</p> <p>You call this action from the management account of your organization in the commercial Region to create a standalone AWS account in the AWS GovCloud (US) Region. After the account is created, the management account of an organization in the AWS GovCloud (US) Region can invite it to that organization. For more information on inviting standalone accounts in the AWS GovCloud (US) to join an organization, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> <p>Calling <code>CreateGovCloudAccount</code> is an asynchronous request that AWS performs in the background. Because <code>CreateGovCloudAccount</code> operates asynchronously, it can return a successful completion message even though account initialization might still be in progress. You might need to wait a few minutes before you can successfully access the account. To check the status of the request, do one of the following:</p> <ul> <li> <p>Use the <code>OperationId</code> response element from this operation to provide as a parameter to the <a>DescribeCreateAccountStatus</a> operation.</p> </li> <li> <p>Check the AWS CloudTrail log for the <code>CreateAccountResult</code> event. For information on using AWS CloudTrail with Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_monitoring.html">Monitoring the Activity in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> </ul> <p/> <p>When you call the <code>CreateGovCloudAccount</code> action, you create two accounts: a standalone account in the AWS GovCloud (US) Region and an associated account in the commercial Region for billing and support purposes. The account in the commercial Region is automatically a member of the organization whose credentials made the request. Both accounts are associated with the same email address.</p> <p>A role is created in the new account in the commercial Region that allows the management account in the organization in the commercial Region to assume it. An AWS GovCloud (US) account is then created and associated with the commercial account that you just created. A role is also created in the new AWS GovCloud (US) account that can be assumed by the AWS GovCloud (US) account that is associated with the management account of the commercial organization. For more information and to view a diagram that explains how account access works, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> <p>For more information about creating accounts, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_create.html">Creating an AWS Account in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> <important> <ul> <li> <p>When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required for the account to operate as a standalone account is <i>not</i> automatically collected. This includes a payment method and signing the end user license agreement (EULA). If you must remove an account from your organization later, you can do so only after you provide the missing information. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization as a member account</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>If you get an exception that indicates that you exceeded your account limits for the organization, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>If you get an exception that indicates that the operation failed because your organization is still initializing, wait one hour and then try again. If the error persists, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>Using <code>CreateGovCloudAccount</code> to create multiple temporary accounts isn't recommended. You can only close an account from the AWS Billing and Cost Management console, and you must be signed in as the root user. For information on the requirements and process for closing an account, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_close.html">Closing an AWS Account</a> in the <i>AWS Organizations User Guide</i>.</p> </li> </ul> </important> <note> <p>When you create a member account with this operation, you can choose whether to create the account with the <b>IAM User and Role Access to Billing Information</b> switch enabled. If you enable it, IAM users and roles that have appropriate permissions can view billing information for the account. If you disable it, only the account root user can access billing information. For information about how to disable this switch for an account, see <a href="https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html">Granting Access to Your Billing Information and Tools</a>.</p> </note></p>
async fn create_gov_cloud_account(
&self,
input: CreateGovCloudAccountRequest,
) -> Result<CreateGovCloudAccountResponse, RusotoError<CreateGovCloudAccountError>>;
/// <p>Creates an AWS organization. The account whose user is calling the <code>CreateOrganization</code> operation automatically becomes the <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_getting-started_concepts.html#account">management account</a> of the new organization.</p> <p>This operation must be called using credentials from the account that is to become the new organization's management account. The principal must also have the relevant IAM permissions.</p> <p>By default (or if you set the <code>FeatureSet</code> parameter to <code>ALL</code>), the new organization is created with all features enabled and service control policies automatically enabled in the root. If you instead choose to create the organization supporting only the consolidated billing features by setting the <code>FeatureSet</code> parameter to <code>CONSOLIDATED_BILLING"</code>, no policy types are enabled by default, and you can't use organization policies</p>
async fn create_organization(
&self,
input: CreateOrganizationRequest,
) -> Result<CreateOrganizationResponse, RusotoError<CreateOrganizationError>>;
/// <p>Creates an organizational unit (OU) within a root or parent OU. An OU is a container for accounts that enables you to organize your accounts to apply policies according to your business requirements. The number of levels deep that you can nest OUs is dependent upon the policy types enabled for that root. For service control policies, the limit is five.</p> <p>For more information about OUs, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_ous.html">Managing Organizational Units</a> in the <i>AWS Organizations User Guide.</i> </p> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>This operation can be called only from the organization's management account.</p>
async fn create_organizational_unit(
&self,
input: CreateOrganizationalUnitRequest,
) -> Result<CreateOrganizationalUnitResponse, RusotoError<CreateOrganizationalUnitError>>;
/// <p>Creates a policy of a specified type that you can attach to a root, an organizational unit (OU), or an individual AWS account.</p> <p>For more information about policies and their use, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html">Managing Organization Policies</a>.</p> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>This operation can be called only from the organization's management account.</p>
async fn create_policy(
&self,
input: CreatePolicyRequest,
) -> Result<CreatePolicyResponse, RusotoError<CreatePolicyError>>;
/// <p>Declines a handshake request. This sets the handshake state to <code>DECLINED</code> and effectively deactivates the request.</p> <p>This operation can be called only from the account that received the handshake. The originator of the handshake can use <a>CancelHandshake</a> instead. The originator can't reactivate a declined request, but can reinitiate the process with a new handshake request.</p> <p>After you decline a handshake, it continues to appear in the results of relevant APIs for only 30 days. After that, it's deleted.</p>
async fn decline_handshake(
&self,
input: DeclineHandshakeRequest,
) -> Result<DeclineHandshakeResponse, RusotoError<DeclineHandshakeError>>;
/// <p>Deletes the organization. You can delete an organization only by using credentials from the management account. The organization must be empty of member accounts.</p>
async fn delete_organization(&self) -> Result<(), RusotoError<DeleteOrganizationError>>;
/// <p>Deletes an organizational unit (OU) from a root or another OU. You must first remove all accounts and child OUs from the OU that you want to delete.</p> <p>This operation can be called only from the organization's management account.</p>
async fn delete_organizational_unit(
&self,
input: DeleteOrganizationalUnitRequest,
) -> Result<(), RusotoError<DeleteOrganizationalUnitError>>;
/// <p>Deletes the specified policy from your organization. Before you perform this operation, you must first detach the policy from all organizational units (OUs), roots, and accounts.</p> <p>This operation can be called only from the organization's management account.</p>
async fn delete_policy(
&self,
input: DeletePolicyRequest,
) -> Result<(), RusotoError<DeletePolicyError>>;
/// <p>Removes the specified member AWS account as a delegated administrator for the specified AWS service.</p> <important> <p>Deregistering a delegated administrator can have unintended impacts on the functionality of the enabled AWS service. See the documentation for the enabled service before you deregister a delegated administrator so that you understand any potential impacts.</p> </important> <p>You can run this action only for AWS services that support this feature. For a current list of services that support it, see the column <i>Supports Delegated Administrator</i> in the table at <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services_list.html">AWS Services that you can use with AWS Organizations</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account.</p>
async fn deregister_delegated_administrator(
&self,
input: DeregisterDelegatedAdministratorRequest,
) -> Result<(), RusotoError<DeregisterDelegatedAdministratorError>>;
/// <p>Retrieves AWS Organizations-related information about the specified account.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_account(
&self,
input: DescribeAccountRequest,
) -> Result<DescribeAccountResponse, RusotoError<DescribeAccountError>>;
/// <p>Retrieves the current status of an asynchronous request to create an account.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_create_account_status(
&self,
input: DescribeCreateAccountStatusRequest,
) -> Result<DescribeCreateAccountStatusResponse, RusotoError<DescribeCreateAccountStatusError>>;
/// <p>Returns the contents of the effective policy for specified policy type and account. The effective policy is the aggregation of any policies of the specified type that the account inherits, plus any policy of that type that is directly attached to the account.</p> <p>This operation applies only to policy types <i>other</i> than service control policies (SCPs).</p> <p>For more information about policy inheritance, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies-inheritance.html">How Policy Inheritance Works</a> in the <i>AWS Organizations User Guide</i>.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_effective_policy(
&self,
input: DescribeEffectivePolicyRequest,
) -> Result<DescribeEffectivePolicyResponse, RusotoError<DescribeEffectivePolicyError>>;
/// <p>Retrieves information about a previously requested handshake. The handshake ID comes from the response to the original <a>InviteAccountToOrganization</a> operation that generated the handshake.</p> <p>You can access handshakes that are <code>ACCEPTED</code>, <code>DECLINED</code>, or <code>CANCELED</code> for only 30 days after they change to that state. They're then deleted and no longer accessible.</p> <p>This operation can be called from any account in the organization.</p>
async fn describe_handshake(
&self,
input: DescribeHandshakeRequest,
) -> Result<DescribeHandshakeResponse, RusotoError<DescribeHandshakeError>>;
/// <p><p>Retrieves information about the organization that the user's account belongs to.</p> <p>This operation can be called from any account in the organization.</p> <note> <p>Even if a policy type is shown as available in the organization, you can disable it separately at the root level with <a>DisablePolicyType</a>. Use <a>ListRoots</a> to see the status of policy types for a specified root.</p> </note></p>
async fn describe_organization(
&self,
) -> Result<DescribeOrganizationResponse, RusotoError<DescribeOrganizationError>>;
/// <p>Retrieves information about an organizational unit (OU).</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_organizational_unit(
&self,
input: DescribeOrganizationalUnitRequest,
) -> Result<DescribeOrganizationalUnitResponse, RusotoError<DescribeOrganizationalUnitError>>;
/// <p>Retrieves information about a policy.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_policy(
&self,
input: DescribePolicyRequest,
) -> Result<DescribePolicyResponse, RusotoError<DescribePolicyError>>;
/// <p>Detaches a policy from a target root, organizational unit (OU), or account.</p> <important> <p>If the policy being detached is a service control policy (SCP), the changes to permissions for AWS Identity and Access Management (IAM) users and roles in affected accounts are immediate.</p> </important> <p>Every root, OU, and account must have at least one SCP attached. If you want to replace the default <code>FullAWSAccess</code> policy with an SCP that limits the permissions that can be delegated, you must attach the replacement SCP before you can remove the default SCP. This is the authorization strategy of an "<a href="https://docs.aws.amazon.com/organizations/latest/userguide/SCP_strategies.html#orgs_policies_allowlist">allow list</a>". If you instead attach a second SCP and leave the <code>FullAWSAccess</code> SCP still attached, and specify <code>"Effect": "Deny"</code> in the second SCP to override the <code>"Effect": "Allow"</code> in the <code>FullAWSAccess</code> policy (or any other attached SCP), you're using the authorization strategy of a "<a href="https://docs.aws.amazon.com/organizations/latest/userguide/SCP_strategies.html#orgs_policies_denylist">deny list</a>".</p> <p>This operation can be called only from the organization's management account.</p>
async fn detach_policy(
&self,
input: DetachPolicyRequest,
) -> Result<(), RusotoError<DetachPolicyError>>;
/// <p>Disables the integration of an AWS service (the service that is specified by <code>ServicePrincipal</code>) with AWS Organizations. When you disable integration, the specified service no longer can create a <a href="http://docs.aws.amazon.com/IAM/latest/UserGuide/using-service-linked-roles.html">service-linked role</a> in <i>new</i> accounts in your organization. This means the service can't perform operations on your behalf on any new accounts in your organization. The service can still perform operations in older accounts until the service completes its clean-up from AWS Organizations.</p> <important> <p>We <b> <i>strongly recommend</i> </b> that you don't use this command to disable integration between AWS Organizations and the specified AWS service. Instead, use the console or commands that are provided by the specified service. This lets the trusted service perform any required initialization when enabling trusted access, such as creating any required resources and any required clean up of resources when disabling trusted access. </p> <p>For information about how to disable trusted service access to your organization using the trusted service, see the <b>Learn more</b> link under the <b>Supports Trusted Access</b> column at <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services_list.html">AWS services that you can use with AWS Organizations</a>. on this page.</p> <p>If you disable access by using this command, it causes the following actions to occur:</p> <ul> <li> <p>The service can no longer create a service-linked role in the accounts in your organization. This means that the service can't perform operations on your behalf on any new accounts in your organization. The service can still perform operations in older accounts until the service completes its clean-up from AWS Organizations. </p> </li> <li> <p>The service can no longer perform tasks in the member accounts in the organization, unless those operations are explicitly permitted by the IAM policies that are attached to your roles. This includes any data aggregation from the member accounts to the management account, or to a delegated administrator account, where relevant.</p> </li> <li> <p>Some services detect this and clean up any remaining data or resources related to the integration, while other services stop accessing the organization but leave any historical data and configuration in place to support a possible re-enabling of the integration.</p> </li> </ul> <p>Using the other service's console or commands to disable the integration ensures that the other service is aware that it can clean up any resources that are required only for the integration. How the service cleans up its resources in the organization's accounts depends on that service. For more information, see the documentation for the other AWS service. </p> </important> <p>After you perform the <code>DisableAWSServiceAccess</code> operation, the specified service can no longer perform operations in your organization's accounts </p> <p>For more information about integrating other services with AWS Organizations, including the list of services that work with Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html">Integrating AWS Organizations with Other AWS Services</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account.</p>
async fn disable_aws_service_access(
&self,
input: DisableAWSServiceAccessRequest,
) -> Result<(), RusotoError<DisableAWSServiceAccessError>>;
/// <p>Disables an organizational policy type in a root. A policy of a certain type can be attached to entities in a root only if that type is enabled in the root. After you perform this operation, you no longer can attach policies of the specified type to that root or to any organizational unit (OU) or account in that root. You can undo this by using the <a>EnablePolicyType</a> operation.</p> <p>This is an asynchronous request that AWS performs in the background. If you disable a policy type for a root, it still appears enabled for the organization if <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">all features</a> are enabled for the organization. AWS recommends that you first use <a>ListRoots</a> to see the status of policy types for a specified root, and then use this operation.</p> <p>This operation can be called only from the organization's management account.</p> <p> To view the status of available policy types in the organization, use <a>DescribeOrganization</a>.</p>
async fn disable_policy_type(
&self,
input: DisablePolicyTypeRequest,
) -> Result<DisablePolicyTypeResponse, RusotoError<DisablePolicyTypeError>>;
/// <p>Enables the integration of an AWS service (the service that is specified by <code>ServicePrincipal</code>) with AWS Organizations. When you enable integration, you allow the specified service to create a <a href="http://docs.aws.amazon.com/IAM/latest/UserGuide/using-service-linked-roles.html">service-linked role</a> in all the accounts in your organization. This allows the service to perform operations on your behalf in your organization and its accounts.</p> <important> <p>We recommend that you enable integration between AWS Organizations and the specified AWS service by using the console or commands that are provided by the specified service. Doing so ensures that the service is aware that it can create the resources that are required for the integration. How the service creates those resources in the organization's accounts depends on that service. For more information, see the documentation for the other AWS service.</p> </important> <p>For more information about enabling services to integrate with AWS Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html">Integrating AWS Organizations with Other AWS Services</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account and only if the organization has <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">enabled all features</a>.</p>
async fn enable_aws_service_access(
&self,
input: EnableAWSServiceAccessRequest,
) -> Result<(), RusotoError<EnableAWSServiceAccessError>>;
/// <p>Enables all features in an organization. This enables the use of organization policies that can restrict the services and actions that can be called in each account. Until you enable all features, you have access only to consolidated billing, and you can't use any of the advanced account administration features that AWS Organizations supports. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">Enabling All Features in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> <important> <p>This operation is required only for organizations that were created explicitly with only the consolidated billing features enabled. Calling this operation sends a handshake to every invited account in the organization. The feature set change can be finalized and the additional features enabled only after all administrators in the invited accounts approve the change by accepting the handshake.</p> </important> <p>After you enable all features, you can separately enable or disable individual policy types in a root using <a>EnablePolicyType</a> and <a>DisablePolicyType</a>. To see the status of policy types in a root, use <a>ListRoots</a>.</p> <p>After all invited member accounts accept the handshake, you finalize the feature set change by accepting the handshake that contains <code>"Action": "ENABLE_ALL_FEATURES"</code>. This completes the change.</p> <p>After you enable all features in your organization, the management account in the organization can apply policies on all member accounts. These policies can restrict what users and even administrators in those accounts can do. The management account can apply policies that prevent accounts from leaving the organization. Ensure that your account administrators are aware of this.</p> <p>This operation can be called only from the organization's management account.</p>
async fn enable_all_features(
&self,
) -> Result<EnableAllFeaturesResponse, RusotoError<EnableAllFeaturesError>>;
/// <p>Enables a policy type in a root. After you enable a policy type in a root, you can attach policies of that type to the root, any organizational unit (OU), or account in that root. You can undo this by using the <a>DisablePolicyType</a> operation.</p> <p>This is an asynchronous request that AWS performs in the background. AWS recommends that you first use <a>ListRoots</a> to see the status of policy types for a specified root, and then use this operation.</p> <p>This operation can be called only from the organization's management account.</p> <p>You can enable a policy type in a root only if that policy type is available in the organization. To view the status of available policy types in the organization, use <a>DescribeOrganization</a>.</p>
async fn enable_policy_type(
&self,
input: EnablePolicyTypeRequest,
) -> Result<EnablePolicyTypeResponse, RusotoError<EnablePolicyTypeError>>;
/// <p>Sends an invitation to another account to join your organization as a member account. AWS Organizations sends email on your behalf to the email address that is associated with the other account's owner. The invitation is implemented as a <a>Handshake</a> whose details are in the response.</p> <important> <ul> <li> <p>You can invite AWS accounts only from the same seller as the management account. For example, if your organization's management account was created by Amazon Internet Services Pvt. Ltd (AISPL), an AWS seller in India, you can invite only other AISPL accounts to your organization. You can't combine accounts from AISPL and AWS or from any other AWS seller. For more information, see <a href="http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/useconsolidatedbilliing-India.html">Consolidated Billing in India</a>.</p> </li> <li> <p>If you receive an exception that indicates that you exceeded your account limits for the organization or that the operation failed because your organization is still initializing, wait one hour and then try again. If the error persists after an hour, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> </ul> </important> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>This operation can be called only from the organization's management account.</p>
async fn invite_account_to_organization(
&self,
input: InviteAccountToOrganizationRequest,
) -> Result<InviteAccountToOrganizationResponse, RusotoError<InviteAccountToOrganizationError>>;
/// <p><p>Removes a member account from its parent organization. This version of the operation is performed by the account that wants to leave. To remove a member account as a user in the management account, use <a>RemoveAccountFromOrganization</a> instead.</p> <p>This operation can be called only from a member account in the organization.</p> <important> <ul> <li> <p>The management account in an organization with all features enabled can set service control policies (SCPs) that can restrict what administrators of member accounts can do. This includes preventing them from successfully calling <code>LeaveOrganization</code> and leaving the organization.</p> </li> <li> <p>You can leave an organization as a member account only if the account is configured with the information required to operate as a standalone account. When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required of standalone accounts is <i>not</i> automatically collected. For each account that you want to make standalone, you must perform the following steps. If any of the steps are already completed for this account, that step doesn't appear.</p> <ul> <li> <p>Choose a support plan</p> </li> <li> <p>Provide and verify the required contact information</p> </li> <li> <p>Provide a current payment method</p> </li> </ul> <p>AWS uses the payment method to charge for any billable (not free tier) AWS activity that occurs while the account isn't attached to an organization. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>The account that you want to leave must not be a delegated administrator account for any AWS service enabled for your organization. If the account is a delegated administrator, you must first change the delegated administrator account to another account that is remaining in the organization.</p> </li> <li> <p>You can leave an organization only after you enable IAM user access to billing in your account. For more information, see <a href="http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html#ControllingAccessWebsite-Activate">Activating Access to the Billing and Cost Management Console</a> in the <i>AWS Billing and Cost Management User Guide.</i> </p> </li> <li> <p>After the account leaves the organization, all tags that were attached to the account object in the organization are deleted. AWS accounts outside of an organization do not support tags.</p> </li> <li> <p>A newly created account has a waiting period before it can be removed from its organization. If you get an error that indicates that a wait period is required, then try again in a few days.</p> </li> </ul> </important></p>
async fn leave_organization(&self) -> Result<(), RusotoError<LeaveOrganizationError>>;
/// <p>Returns a list of the AWS services that you enabled to integrate with your organization. After a service on this list creates the resources that it requires for the integration, it can perform operations on your organization and its accounts.</p> <p>For more information about integrating other services with AWS Organizations, including the list of services that currently work with Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html">Integrating AWS Organizations with Other AWS Services</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_aws_service_access_for_organization(
&self,
input: ListAWSServiceAccessForOrganizationRequest,
) -> Result<
ListAWSServiceAccessForOrganizationResponse,
RusotoError<ListAWSServiceAccessForOrganizationError>,
>;
/// <p>Lists all the accounts in the organization. To request only the accounts in a specified root or organizational unit (OU), use the <a>ListAccountsForParent</a> operation instead.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_accounts(
&self,
input: ListAccountsRequest,
) -> Result<ListAccountsResponse, RusotoError<ListAccountsError>>;
/// <p>Lists the accounts in an organization that are contained by the specified target root or organizational unit (OU). If you specify the root, you get a list of all the accounts that aren't in any OU. If you specify an OU, you get a list of all the accounts in only that OU and not in any child OUs. To get a list of all accounts in the organization, use the <a>ListAccounts</a> operation.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_accounts_for_parent(
&self,
input: ListAccountsForParentRequest,
) -> Result<ListAccountsForParentResponse, RusotoError<ListAccountsForParentError>>;
/// <p>Lists all of the organizational units (OUs) or accounts that are contained in the specified parent OU or root. This operation, along with <a>ListParents</a> enables you to traverse the tree structure that makes up this root.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_children(
&self,
input: ListChildrenRequest,
) -> Result<ListChildrenResponse, RusotoError<ListChildrenError>>;
/// <p>Lists the account creation requests that match the specified status that is currently being tracked for the organization.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_create_account_status(
&self,
input: ListCreateAccountStatusRequest,
) -> Result<ListCreateAccountStatusResponse, RusotoError<ListCreateAccountStatusError>>;
/// <p>Lists the AWS accounts that are designated as delegated administrators in this organization.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_delegated_administrators(
&self,
input: ListDelegatedAdministratorsRequest,
) -> Result<ListDelegatedAdministratorsResponse, RusotoError<ListDelegatedAdministratorsError>>;
/// <p>List the AWS services for which the specified account is a delegated administrator.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_delegated_services_for_account(
&self,
input: ListDelegatedServicesForAccountRequest,
) -> Result<
ListDelegatedServicesForAccountResponse,
RusotoError<ListDelegatedServicesForAccountError>,
>;
/// <p>Lists the current handshakes that are associated with the account of the requesting user.</p> <p>Handshakes that are <code>ACCEPTED</code>, <code>DECLINED</code>, or <code>CANCELED</code> appear in the results of this API for only 30 days after changing to that state. After that, they're deleted and no longer accessible.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called from any account in the organization.</p>
async fn list_handshakes_for_account(
&self,
input: ListHandshakesForAccountRequest,
) -> Result<ListHandshakesForAccountResponse, RusotoError<ListHandshakesForAccountError>>;
/// <p>Lists the handshakes that are associated with the organization that the requesting user is part of. The <code>ListHandshakesForOrganization</code> operation returns a list of handshake structures. Each structure contains details and status about a handshake.</p> <p>Handshakes that are <code>ACCEPTED</code>, <code>DECLINED</code>, or <code>CANCELED</code> appear in the results of this API for only 30 days after changing to that state. After that, they're deleted and no longer accessible.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_handshakes_for_organization(
&self,
input: ListHandshakesForOrganizationRequest,
) -> Result<
ListHandshakesForOrganizationResponse,
RusotoError<ListHandshakesForOrganizationError>,
>;
/// <p>Lists the organizational units (OUs) in a parent organizational unit or root.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_organizational_units_for_parent(
&self,
input: ListOrganizationalUnitsForParentRequest,
) -> Result<
ListOrganizationalUnitsForParentResponse,
RusotoError<ListOrganizationalUnitsForParentError>,
>;
/// <p><p>Lists the root or organizational units (OUs) that serve as the immediate parent of the specified child OU or account. This operation, along with <a>ListChildren</a> enables you to traverse the tree structure that makes up this root.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p> <note> <p>In the current release, a child can have only a single parent.</p> </note></p>
async fn list_parents(
&self,
input: ListParentsRequest,
) -> Result<ListParentsResponse, RusotoError<ListParentsError>>;
/// <p>Retrieves the list of all policies in an organization of a specified type.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_policies(
&self,
input: ListPoliciesRequest,
) -> Result<ListPoliciesResponse, RusotoError<ListPoliciesError>>;
/// <p>Lists the policies that are directly attached to the specified target root, organizational unit (OU), or account. You must specify the policy type that you want included in the returned list.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_policies_for_target(
&self,
input: ListPoliciesForTargetRequest,
) -> Result<ListPoliciesForTargetResponse, RusotoError<ListPoliciesForTargetError>>;
/// <p><p>Lists the roots that are defined in the current organization.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p> <note> <p>Policy types can be enabled and disabled in roots. This is distinct from whether they're available in the organization. When you enable all features, you make policy types available for use in that organization. Individual policy types can then be enabled and disabled in a root. To see the availability of a policy type in an organization, use <a>DescribeOrganization</a>.</p> </note></p>
async fn list_roots(
&self,
input: ListRootsRequest,
) -> Result<ListRootsResponse, RusotoError<ListRootsError>>;
/// <p>Lists tags that are attached to the specified resource.</p> <p>You can attach tags to the following resources in AWS Organizations.</p> <ul> <li> <p>AWS account</p> </li> <li> <p>Organization root</p> </li> <li> <p>Organizational unit (OU)</p> </li> <li> <p>Policy (any type)</p> </li> </ul> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_tags_for_resource(
&self,
input: ListTagsForResourceRequest,
) -> Result<ListTagsForResourceResponse, RusotoError<ListTagsForResourceError>>;
/// <p>Lists all the roots, organizational units (OUs), and accounts that the specified policy is attached to.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_targets_for_policy(
&self,
input: ListTargetsForPolicyRequest,
) -> Result<ListTargetsForPolicyResponse, RusotoError<ListTargetsForPolicyError>>;
/// <p>Moves an account from its current source parent root or organizational unit (OU) to the specified destination parent root or OU.</p> <p>This operation can be called only from the organization's management account.</p>
async fn move_account(
&self,
input: MoveAccountRequest,
) -> Result<(), RusotoError<MoveAccountError>>;
/// <p>Enables the specified member account to administer the Organizations features of the specified AWS service. It grants read-only access to AWS Organizations service data. The account still requires IAM permissions to access and administer the AWS service.</p> <p>You can run this action only for AWS services that support this feature. For a current list of services that support it, see the column <i>Supports Delegated Administrator</i> in the table at <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services_list.html">AWS Services that you can use with AWS Organizations</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account.</p>
async fn register_delegated_administrator(
&self,
input: RegisterDelegatedAdministratorRequest,
) -> Result<(), RusotoError<RegisterDelegatedAdministratorError>>;
/// <p><p>Removes the specified account from the organization.</p> <p>The removed account becomes a standalone account that isn't a member of any organization. It's no longer subject to any policies and is responsible for its own bill payments. The organization's management account is no longer charged for any expenses accrued by the member account after it's removed from the organization.</p> <p>This operation can be called only from the organization's management account. Member accounts can remove themselves with <a>LeaveOrganization</a> instead.</p> <important> <ul> <li> <p>You can remove an account from your organization only if the account is configured with the information required to operate as a standalone account. When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required of standalone accounts is <i>not</i> automatically collected. For an account that you want to make standalone, you must choose a support plan, provide and verify the required contact information, and provide a current payment method. AWS uses the payment method to charge for any billable (not free tier) AWS activity that occurs while the account isn't attached to an organization. To remove an account that doesn't yet have this information, you must sign in as the member account and follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>The account that you want to leave must not be a delegated administrator account for any AWS service enabled for your organization. If the account is a delegated administrator, you must first change the delegated administrator account to another account that is remaining in the organization.</p> </li> <li> <p>After the account leaves the organization, all tags that were attached to the account object in the organization are deleted. AWS accounts outside of an organization do not support tags.</p> </li> </ul> </important></p>
async fn remove_account_from_organization(
&self,
input: RemoveAccountFromOrganizationRequest,
) -> Result<(), RusotoError<RemoveAccountFromOrganizationError>>;
/// <p>Adds one or more tags to the specified resource.</p> <p>Currently, you can attach tags to the following resources in AWS Organizations.</p> <ul> <li> <p>AWS account</p> </li> <li> <p>Organization root</p> </li> <li> <p>Organizational unit (OU)</p> </li> <li> <p>Policy (any type)</p> </li> </ul> <p>This operation can be called only from the organization's management account.</p>
async fn tag_resource(
&self,
input: TagResourceRequest,
) -> Result<(), RusotoError<TagResourceError>>;
/// <p>Removes any tags with the specified keys from the specified resource.</p> <p>You can attach tags to the following resources in AWS Organizations.</p> <ul> <li> <p>AWS account</p> </li> <li> <p>Organization root</p> </li> <li> <p>Organizational unit (OU)</p> </li> <li> <p>Policy (any type)</p> </li> </ul> <p>This operation can be called only from the organization's management account.</p>
async fn untag_resource(
&self,
input: UntagResourceRequest,
) -> Result<(), RusotoError<UntagResourceError>>;
/// <p>Renames the specified organizational unit (OU). The ID and ARN don't change. The child OUs and accounts remain in place, and any attached policies of the OU remain attached.</p> <p>This operation can be called only from the organization's management account.</p>
async fn update_organizational_unit(
&self,
input: UpdateOrganizationalUnitRequest,
) -> Result<UpdateOrganizationalUnitResponse, RusotoError<UpdateOrganizationalUnitError>>;
/// <p>Updates an existing policy with a new name, description, or content. If you don't supply any parameter, that value remains unchanged. You can't change a policy's type.</p> <p>This operation can be called only from the organization's management account.</p>
async fn update_policy(
&self,
input: UpdatePolicyRequest,
) -> Result<UpdatePolicyResponse, RusotoError<UpdatePolicyError>>;
}
/// A client for the Organizations API.
#[derive(Clone)]
pub struct OrganizationsClient {
client: Client,
region: region::Region,
}
impl OrganizationsClient {
/// Creates a client backed by the default tokio event loop.
///
/// The client will use the default credentials provider and tls client.
pub fn new(region: region::Region) -> OrganizationsClient {
OrganizationsClient {
client: Client::shared(),
region,
}
}
pub fn new_with<P, D>(
request_dispatcher: D,
credentials_provider: P,
region: region::Region,
) -> OrganizationsClient
where
P: ProvideAwsCredentials + Send + Sync + 'static,
D: DispatchSignedRequest + Send + Sync + 'static,
{
OrganizationsClient {
client: Client::new_with(credentials_provider, request_dispatcher),
region,
}
}
pub fn new_with_client(client: Client, region: region::Region) -> OrganizationsClient {
OrganizationsClient { client, region }
}
}
#[async_trait]
impl Organizations for OrganizationsClient {
/// <p>Sends a response to the originator of a handshake agreeing to the action proposed by the handshake request.</p> <p>This operation can be called only by the following principals when they also have the relevant IAM permissions:</p> <ul> <li> <p> <b>Invitation to join</b> or <b>Approve all features request</b> handshakes: only a principal from the member account.</p> <p>The user who calls the API for an invitation to join must have the <code>organizations:AcceptHandshake</code> permission. If you enabled all features in the organization, the user must also have the <code>iam:CreateServiceLinkedRole</code> permission so that AWS Organizations can create the required service-linked role named <code>AWSServiceRoleForOrganizations</code>. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integration_services.html#orgs_integration_service-linked-roles">AWS Organizations and Service-Linked Roles</a> in the <i>AWS Organizations User Guide</i>.</p> </li> <li> <p> <b>Enable all features final confirmation</b> handshake: only a principal from the management account.</p> <p>For more information about invitations, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_invites.html">Inviting an AWS Account to Join Your Organization</a> in the <i>AWS Organizations User Guide.</i> For more information about requests to enable all features in the organization, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">Enabling All Features in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> </ul> <p>After you accept a handshake, it continues to appear in the results of relevant APIs for only 30 days. After that, it's deleted.</p>
async fn accept_handshake(
&self,
input: AcceptHandshakeRequest,
) -> Result<AcceptHandshakeResponse, RusotoError<AcceptHandshakeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.AcceptHandshake");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, AcceptHandshakeError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<AcceptHandshakeResponse, _>()
}
/// <p>Attaches a policy to a root, an organizational unit (OU), or an individual account. How the policy affects accounts depends on the type of policy. Refer to the <i>AWS Organizations User Guide</i> for information about each policy type:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_ai-opt-out.html">AISERVICES_OPT_OUT_POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_backup.html">BACKUP_POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_scp.html">SERVICE_CONTROL_POLICY</a> </p> </li> <li> <p> <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_tag-policies.html">TAG_POLICY</a> </p> </li> </ul> <p>This operation can be called only from the organization's management account.</p>
async fn attach_policy(
&self,
input: AttachPolicyRequest,
) -> Result<(), RusotoError<AttachPolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.AttachPolicy");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, AttachPolicyError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Cancels a handshake. Canceling a handshake sets the handshake state to <code>CANCELED</code>.</p> <p>This operation can be called only from the account that originated the handshake. The recipient of the handshake can't cancel it, but can use <a>DeclineHandshake</a> instead. After a handshake is canceled, the recipient can no longer respond to that handshake.</p> <p>After you cancel a handshake, it continues to appear in the results of relevant APIs for only 30 days. After that, it's deleted.</p>
async fn cancel_handshake(
&self,
input: CancelHandshakeRequest,
) -> Result<CancelHandshakeResponse, RusotoError<CancelHandshakeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.CancelHandshake");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CancelHandshakeError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<CancelHandshakeResponse, _>()
}
/// <p><p>Creates an AWS account that is automatically a member of the organization whose credentials made the request. This is an asynchronous request that AWS performs in the background. Because <code>CreateAccount</code> operates asynchronously, it can return a successful completion message even though account initialization might still be in progress. You might need to wait a few minutes before you can successfully access the account. To check the status of the request, do one of the following:</p> <ul> <li> <p>Use the <code>Id</code> member of the <code>CreateAccountStatus</code> response element from this operation to provide as a parameter to the <a>DescribeCreateAccountStatus</a> operation.</p> </li> <li> <p>Check the AWS CloudTrail log for the <code>CreateAccountResult</code> event. For information on using AWS CloudTrail with AWS Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_security_incident-response.html#orgs_cloudtrail-integration">Logging and monitoring in AWS Organizations</a> in the <i>AWS Organizations User Guide.</i> </p> </li> </ul> <p>The user who calls the API to create an account must have the <code>organizations:CreateAccount</code> permission. If you enabled all features in the organization, AWS Organizations creates the required service-linked role named <code>AWSServiceRoleForOrganizations</code>. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html#orgs_integrate_services-using_slrs">AWS Organizations and Service-Linked Roles</a> in the <i>AWS Organizations User Guide</i>.</p> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>AWS Organizations preconfigures the new member account with a role (named <code>OrganizationAccountAccessRole</code> by default) that grants users in the management account administrator permissions in the new member account. Principals in the management account can assume the role. AWS Organizations clones the company name and address information for the new account from the organization's management account.</p> <p>This operation can be called only from the organization's management account.</p> <p>For more information about creating accounts, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_create.html">Creating an AWS Account in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> <important> <ul> <li> <p>When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required for the account to operate as a standalone account, such as a payment method and signing the end user license agreement (EULA) is <i>not</i> automatically collected. If you must remove an account from your organization later, you can do so only after you provide the missing information. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization as a member account</a> in the <i>AWS Organizations User Guide</i>.</p> </li> <li> <p>If you get an exception that indicates that you exceeded your account limits for the organization, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>If you get an exception that indicates that the operation failed because your organization is still initializing, wait one hour and then try again. If the error persists, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>Using <code>CreateAccount</code> to create multiple temporary accounts isn't recommended. You can only close an account from the Billing and Cost Management Console, and you must be signed in as the root user. For information on the requirements and process for closing an account, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_close.html">Closing an AWS Account</a> in the <i>AWS Organizations User Guide</i>.</p> </li> </ul> </important> <note> <p>When you create a member account with this operation, you can choose whether to create the account with the <b>IAM User and Role Access to Billing Information</b> switch enabled. If you enable it, IAM users and roles that have appropriate permissions can view billing information for the account. If you disable it, only the account root user can access billing information. For information about how to disable this switch for an account, see <a href="https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html">Granting Access to Your Billing Information and Tools</a>.</p> </note></p>
async fn create_account(
&self,
input: CreateAccountRequest,
) -> Result<CreateAccountResponse, RusotoError<CreateAccountError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.CreateAccount");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CreateAccountError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<CreateAccountResponse, _>()
}
/// <p><p>This action is available if all of the following are true:</p> <ul> <li> <p>You're authorized to create accounts in the AWS GovCloud (US) Region. For more information on the AWS GovCloud (US) Region, see the <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/welcome.html"> <i>AWS GovCloud User Guide</i>.</a> </p> </li> <li> <p>You already have an account in the AWS GovCloud (US) Region that is paired with a management account of an organization in the commercial Region.</p> </li> <li> <p>You call this action from the management account of your organization in the commercial Region.</p> </li> <li> <p>You have the <code>organizations:CreateGovCloudAccount</code> permission. </p> </li> </ul> <p>AWS Organizations automatically creates the required service-linked role named <code>AWSServiceRoleForOrganizations</code>. For more information, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html#orgs_integrate_services-using_slrs">AWS Organizations and Service-Linked Roles</a> in the <i>AWS Organizations User Guide.</i> </p> <p>AWS automatically enables AWS CloudTrail for AWS GovCloud (US) accounts, but you should also do the following:</p> <ul> <li> <p>Verify that AWS CloudTrail is enabled to store logs.</p> </li> <li> <p>Create an S3 bucket for AWS CloudTrail log storage.</p> <p>For more information, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/verifying-cloudtrail.html">Verifying AWS CloudTrail Is Enabled</a> in the <i>AWS GovCloud User Guide</i>. </p> </li> </ul> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission. The tags are attached to the commercial account associated with the GovCloud account, rather than the GovCloud account itself. To add tags to the GovCloud account, call the <a>TagResource</a> operation in the GovCloud Region after the new GovCloud account exists.</p> <p>You call this action from the management account of your organization in the commercial Region to create a standalone AWS account in the AWS GovCloud (US) Region. After the account is created, the management account of an organization in the AWS GovCloud (US) Region can invite it to that organization. For more information on inviting standalone accounts in the AWS GovCloud (US) to join an organization, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> <p>Calling <code>CreateGovCloudAccount</code> is an asynchronous request that AWS performs in the background. Because <code>CreateGovCloudAccount</code> operates asynchronously, it can return a successful completion message even though account initialization might still be in progress. You might need to wait a few minutes before you can successfully access the account. To check the status of the request, do one of the following:</p> <ul> <li> <p>Use the <code>OperationId</code> response element from this operation to provide as a parameter to the <a>DescribeCreateAccountStatus</a> operation.</p> </li> <li> <p>Check the AWS CloudTrail log for the <code>CreateAccountResult</code> event. For information on using AWS CloudTrail with Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_monitoring.html">Monitoring the Activity in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> </li> </ul> <p/> <p>When you call the <code>CreateGovCloudAccount</code> action, you create two accounts: a standalone account in the AWS GovCloud (US) Region and an associated account in the commercial Region for billing and support purposes. The account in the commercial Region is automatically a member of the organization whose credentials made the request. Both accounts are associated with the same email address.</p> <p>A role is created in the new account in the commercial Region that allows the management account in the organization in the commercial Region to assume it. An AWS GovCloud (US) account is then created and associated with the commercial account that you just created. A role is also created in the new AWS GovCloud (US) account that can be assumed by the AWS GovCloud (US) account that is associated with the management account of the commercial organization. For more information and to view a diagram that explains how account access works, see <a href="http://docs.aws.amazon.com/govcloud-us/latest/UserGuide/govcloud-organizations.html">AWS Organizations</a> in the <i>AWS GovCloud User Guide.</i> </p> <p>For more information about creating accounts, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_create.html">Creating an AWS Account in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> <important> <ul> <li> <p>When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required for the account to operate as a standalone account is <i>not</i> automatically collected. This includes a payment method and signing the end user license agreement (EULA). If you must remove an account from your organization later, you can do so only after you provide the missing information. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization as a member account</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>If you get an exception that indicates that you exceeded your account limits for the organization, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>If you get an exception that indicates that the operation failed because your organization is still initializing, wait one hour and then try again. If the error persists, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> <li> <p>Using <code>CreateGovCloudAccount</code> to create multiple temporary accounts isn't recommended. You can only close an account from the AWS Billing and Cost Management console, and you must be signed in as the root user. For information on the requirements and process for closing an account, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_close.html">Closing an AWS Account</a> in the <i>AWS Organizations User Guide</i>.</p> </li> </ul> </important> <note> <p>When you create a member account with this operation, you can choose whether to create the account with the <b>IAM User and Role Access to Billing Information</b> switch enabled. If you enable it, IAM users and roles that have appropriate permissions can view billing information for the account. If you disable it, only the account root user can access billing information. For information about how to disable this switch for an account, see <a href="https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html">Granting Access to Your Billing Information and Tools</a>.</p> </note></p>
async fn create_gov_cloud_account(
&self,
input: CreateGovCloudAccountRequest,
) -> Result<CreateGovCloudAccountResponse, RusotoError<CreateGovCloudAccountError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.CreateGovCloudAccount",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CreateGovCloudAccountError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<CreateGovCloudAccountResponse, _>()
}
/// <p>Creates an AWS organization. The account whose user is calling the <code>CreateOrganization</code> operation automatically becomes the <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_getting-started_concepts.html#account">management account</a> of the new organization.</p> <p>This operation must be called using credentials from the account that is to become the new organization's management account. The principal must also have the relevant IAM permissions.</p> <p>By default (or if you set the <code>FeatureSet</code> parameter to <code>ALL</code>), the new organization is created with all features enabled and service control policies automatically enabled in the root. If you instead choose to create the organization supporting only the consolidated billing features by setting the <code>FeatureSet</code> parameter to <code>CONSOLIDATED_BILLING"</code>, no policy types are enabled by default, and you can't use organization policies</p>
async fn create_organization(
&self,
input: CreateOrganizationRequest,
) -> Result<CreateOrganizationResponse, RusotoError<CreateOrganizationError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.CreateOrganization",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CreateOrganizationError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<CreateOrganizationResponse, _>()
}
/// <p>Creates an organizational unit (OU) within a root or parent OU. An OU is a container for accounts that enables you to organize your accounts to apply policies according to your business requirements. The number of levels deep that you can nest OUs is dependent upon the policy types enabled for that root. For service control policies, the limit is five.</p> <p>For more information about OUs, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_ous.html">Managing Organizational Units</a> in the <i>AWS Organizations User Guide.</i> </p> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>This operation can be called only from the organization's management account.</p>
async fn create_organizational_unit(
&self,
input: CreateOrganizationalUnitRequest,
) -> Result<CreateOrganizationalUnitResponse, RusotoError<CreateOrganizationalUnitError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.CreateOrganizationalUnit",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CreateOrganizationalUnitError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<CreateOrganizationalUnitResponse, _>()
}
/// <p>Creates a policy of a specified type that you can attach to a root, an organizational unit (OU), or an individual AWS account.</p> <p>For more information about policies and their use, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html">Managing Organization Policies</a>.</p> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>This operation can be called only from the organization's management account.</p>
async fn create_policy(
&self,
input: CreatePolicyRequest,
) -> Result<CreatePolicyResponse, RusotoError<CreatePolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.CreatePolicy");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CreatePolicyError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<CreatePolicyResponse, _>()
}
/// <p>Declines a handshake request. This sets the handshake state to <code>DECLINED</code> and effectively deactivates the request.</p> <p>This operation can be called only from the account that received the handshake. The originator of the handshake can use <a>CancelHandshake</a> instead. The originator can't reactivate a declined request, but can reinitiate the process with a new handshake request.</p> <p>After you decline a handshake, it continues to appear in the results of relevant APIs for only 30 days. After that, it's deleted.</p>
async fn decline_handshake(
&self,
input: DeclineHandshakeRequest,
) -> Result<DeclineHandshakeResponse, RusotoError<DeclineHandshakeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.DeclineHandshake");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DeclineHandshakeError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<DeclineHandshakeResponse, _>()
}
/// <p>Deletes the organization. You can delete an organization only by using credentials from the management account. The organization must be empty of member accounts.</p>
async fn delete_organization(&self) -> Result<(), RusotoError<DeleteOrganizationError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DeleteOrganization",
);
request.set_payload(Some(bytes::Bytes::from_static(b"{}")));
let response = self
.sign_and_dispatch(request, DeleteOrganizationError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Deletes an organizational unit (OU) from a root or another OU. You must first remove all accounts and child OUs from the OU that you want to delete.</p> <p>This operation can be called only from the organization's management account.</p>
async fn delete_organizational_unit(
&self,
input: DeleteOrganizationalUnitRequest,
) -> Result<(), RusotoError<DeleteOrganizationalUnitError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DeleteOrganizationalUnit",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DeleteOrganizationalUnitError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Deletes the specified policy from your organization. Before you perform this operation, you must first detach the policy from all organizational units (OUs), roots, and accounts.</p> <p>This operation can be called only from the organization's management account.</p>
async fn delete_policy(
&self,
input: DeletePolicyRequest,
) -> Result<(), RusotoError<DeletePolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.DeletePolicy");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DeletePolicyError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Removes the specified member AWS account as a delegated administrator for the specified AWS service.</p> <important> <p>Deregistering a delegated administrator can have unintended impacts on the functionality of the enabled AWS service. See the documentation for the enabled service before you deregister a delegated administrator so that you understand any potential impacts.</p> </important> <p>You can run this action only for AWS services that support this feature. For a current list of services that support it, see the column <i>Supports Delegated Administrator</i> in the table at <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services_list.html">AWS Services that you can use with AWS Organizations</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account.</p>
async fn deregister_delegated_administrator(
&self,
input: DeregisterDelegatedAdministratorRequest,
) -> Result<(), RusotoError<DeregisterDelegatedAdministratorError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DeregisterDelegatedAdministrator",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(
request,
DeregisterDelegatedAdministratorError::from_response,
)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Retrieves AWS Organizations-related information about the specified account.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_account(
&self,
input: DescribeAccountRequest,
) -> Result<DescribeAccountResponse, RusotoError<DescribeAccountError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.DescribeAccount");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DescribeAccountError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<DescribeAccountResponse, _>()
}
/// <p>Retrieves the current status of an asynchronous request to create an account.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_create_account_status(
&self,
input: DescribeCreateAccountStatusRequest,
) -> Result<DescribeCreateAccountStatusResponse, RusotoError<DescribeCreateAccountStatusError>>
{
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DescribeCreateAccountStatus",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DescribeCreateAccountStatusError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<DescribeCreateAccountStatusResponse, _>()
}
/// <p>Returns the contents of the effective policy for specified policy type and account. The effective policy is the aggregation of any policies of the specified type that the account inherits, plus any policy of that type that is directly attached to the account.</p> <p>This operation applies only to policy types <i>other</i> than service control policies (SCPs).</p> <p>For more information about policy inheritance, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies-inheritance.html">How Policy Inheritance Works</a> in the <i>AWS Organizations User Guide</i>.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_effective_policy(
&self,
input: DescribeEffectivePolicyRequest,
) -> Result<DescribeEffectivePolicyResponse, RusotoError<DescribeEffectivePolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DescribeEffectivePolicy",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DescribeEffectivePolicyError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<DescribeEffectivePolicyResponse, _>()
}
/// <p>Retrieves information about a previously requested handshake. The handshake ID comes from the response to the original <a>InviteAccountToOrganization</a> operation that generated the handshake.</p> <p>You can access handshakes that are <code>ACCEPTED</code>, <code>DECLINED</code>, or <code>CANCELED</code> for only 30 days after they change to that state. They're then deleted and no longer accessible.</p> <p>This operation can be called from any account in the organization.</p>
async fn describe_handshake(
&self,
input: DescribeHandshakeRequest,
) -> Result<DescribeHandshakeResponse, RusotoError<DescribeHandshakeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DescribeHandshake",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DescribeHandshakeError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<DescribeHandshakeResponse, _>()
}
/// <p><p>Retrieves information about the organization that the user's account belongs to.</p> <p>This operation can be called from any account in the organization.</p> <note> <p>Even if a policy type is shown as available in the organization, you can disable it separately at the root level with <a>DisablePolicyType</a>. Use <a>ListRoots</a> to see the status of policy types for a specified root.</p> </note></p>
async fn describe_organization(
&self,
) -> Result<DescribeOrganizationResponse, RusotoError<DescribeOrganizationError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DescribeOrganization",
);
request.set_payload(Some(bytes::Bytes::from_static(b"{}")));
let response = self
.sign_and_dispatch(request, DescribeOrganizationError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<DescribeOrganizationResponse, _>()
}
/// <p>Retrieves information about an organizational unit (OU).</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_organizational_unit(
&self,
input: DescribeOrganizationalUnitRequest,
) -> Result<DescribeOrganizationalUnitResponse, RusotoError<DescribeOrganizationalUnitError>>
{
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DescribeOrganizationalUnit",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DescribeOrganizationalUnitError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<DescribeOrganizationalUnitResponse, _>()
}
/// <p>Retrieves information about a policy.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn describe_policy(
&self,
input: DescribePolicyRequest,
) -> Result<DescribePolicyResponse, RusotoError<DescribePolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.DescribePolicy");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DescribePolicyError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<DescribePolicyResponse, _>()
}
/// <p>Detaches a policy from a target root, organizational unit (OU), or account.</p> <important> <p>If the policy being detached is a service control policy (SCP), the changes to permissions for AWS Identity and Access Management (IAM) users and roles in affected accounts are immediate.</p> </important> <p>Every root, OU, and account must have at least one SCP attached. If you want to replace the default <code>FullAWSAccess</code> policy with an SCP that limits the permissions that can be delegated, you must attach the replacement SCP before you can remove the default SCP. This is the authorization strategy of an "<a href="https://docs.aws.amazon.com/organizations/latest/userguide/SCP_strategies.html#orgs_policies_allowlist">allow list</a>". If you instead attach a second SCP and leave the <code>FullAWSAccess</code> SCP still attached, and specify <code>"Effect": "Deny"</code> in the second SCP to override the <code>"Effect": "Allow"</code> in the <code>FullAWSAccess</code> policy (or any other attached SCP), you're using the authorization strategy of a "<a href="https://docs.aws.amazon.com/organizations/latest/userguide/SCP_strategies.html#orgs_policies_denylist">deny list</a>".</p> <p>This operation can be called only from the organization's management account.</p>
async fn detach_policy(
&self,
input: DetachPolicyRequest,
) -> Result<(), RusotoError<DetachPolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.DetachPolicy");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DetachPolicyError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Disables the integration of an AWS service (the service that is specified by <code>ServicePrincipal</code>) with AWS Organizations. When you disable integration, the specified service no longer can create a <a href="http://docs.aws.amazon.com/IAM/latest/UserGuide/using-service-linked-roles.html">service-linked role</a> in <i>new</i> accounts in your organization. This means the service can't perform operations on your behalf on any new accounts in your organization. The service can still perform operations in older accounts until the service completes its clean-up from AWS Organizations.</p> <important> <p>We <b> <i>strongly recommend</i> </b> that you don't use this command to disable integration between AWS Organizations and the specified AWS service. Instead, use the console or commands that are provided by the specified service. This lets the trusted service perform any required initialization when enabling trusted access, such as creating any required resources and any required clean up of resources when disabling trusted access. </p> <p>For information about how to disable trusted service access to your organization using the trusted service, see the <b>Learn more</b> link under the <b>Supports Trusted Access</b> column at <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services_list.html">AWS services that you can use with AWS Organizations</a>. on this page.</p> <p>If you disable access by using this command, it causes the following actions to occur:</p> <ul> <li> <p>The service can no longer create a service-linked role in the accounts in your organization. This means that the service can't perform operations on your behalf on any new accounts in your organization. The service can still perform operations in older accounts until the service completes its clean-up from AWS Organizations. </p> </li> <li> <p>The service can no longer perform tasks in the member accounts in the organization, unless those operations are explicitly permitted by the IAM policies that are attached to your roles. This includes any data aggregation from the member accounts to the management account, or to a delegated administrator account, where relevant.</p> </li> <li> <p>Some services detect this and clean up any remaining data or resources related to the integration, while other services stop accessing the organization but leave any historical data and configuration in place to support a possible re-enabling of the integration.</p> </li> </ul> <p>Using the other service's console or commands to disable the integration ensures that the other service is aware that it can clean up any resources that are required only for the integration. How the service cleans up its resources in the organization's accounts depends on that service. For more information, see the documentation for the other AWS service. </p> </important> <p>After you perform the <code>DisableAWSServiceAccess</code> operation, the specified service can no longer perform operations in your organization's accounts </p> <p>For more information about integrating other services with AWS Organizations, including the list of services that work with Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html">Integrating AWS Organizations with Other AWS Services</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account.</p>
async fn disable_aws_service_access(
&self,
input: DisableAWSServiceAccessRequest,
) -> Result<(), RusotoError<DisableAWSServiceAccessError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DisableAWSServiceAccess",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DisableAWSServiceAccessError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Disables an organizational policy type in a root. A policy of a certain type can be attached to entities in a root only if that type is enabled in the root. After you perform this operation, you no longer can attach policies of the specified type to that root or to any organizational unit (OU) or account in that root. You can undo this by using the <a>EnablePolicyType</a> operation.</p> <p>This is an asynchronous request that AWS performs in the background. If you disable a policy type for a root, it still appears enabled for the organization if <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">all features</a> are enabled for the organization. AWS recommends that you first use <a>ListRoots</a> to see the status of policy types for a specified root, and then use this operation.</p> <p>This operation can be called only from the organization's management account.</p> <p> To view the status of available policy types in the organization, use <a>DescribeOrganization</a>.</p>
async fn disable_policy_type(
&self,
input: DisablePolicyTypeRequest,
) -> Result<DisablePolicyTypeResponse, RusotoError<DisablePolicyTypeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.DisablePolicyType",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DisablePolicyTypeError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<DisablePolicyTypeResponse, _>()
}
/// <p>Enables the integration of an AWS service (the service that is specified by <code>ServicePrincipal</code>) with AWS Organizations. When you enable integration, you allow the specified service to create a <a href="http://docs.aws.amazon.com/IAM/latest/UserGuide/using-service-linked-roles.html">service-linked role</a> in all the accounts in your organization. This allows the service to perform operations on your behalf in your organization and its accounts.</p> <important> <p>We recommend that you enable integration between AWS Organizations and the specified AWS service by using the console or commands that are provided by the specified service. Doing so ensures that the service is aware that it can create the resources that are required for the integration. How the service creates those resources in the organization's accounts depends on that service. For more information, see the documentation for the other AWS service.</p> </important> <p>For more information about enabling services to integrate with AWS Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html">Integrating AWS Organizations with Other AWS Services</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account and only if the organization has <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">enabled all features</a>.</p>
async fn enable_aws_service_access(
&self,
input: EnableAWSServiceAccessRequest,
) -> Result<(), RusotoError<EnableAWSServiceAccessError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.EnableAWSServiceAccess",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, EnableAWSServiceAccessError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Enables all features in an organization. This enables the use of organization policies that can restrict the services and actions that can be called in each account. Until you enable all features, you have access only to consolidated billing, and you can't use any of the advanced account administration features that AWS Organizations supports. For more information, see <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html">Enabling All Features in Your Organization</a> in the <i>AWS Organizations User Guide.</i> </p> <important> <p>This operation is required only for organizations that were created explicitly with only the consolidated billing features enabled. Calling this operation sends a handshake to every invited account in the organization. The feature set change can be finalized and the additional features enabled only after all administrators in the invited accounts approve the change by accepting the handshake.</p> </important> <p>After you enable all features, you can separately enable or disable individual policy types in a root using <a>EnablePolicyType</a> and <a>DisablePolicyType</a>. To see the status of policy types in a root, use <a>ListRoots</a>.</p> <p>After all invited member accounts accept the handshake, you finalize the feature set change by accepting the handshake that contains <code>"Action": "ENABLE_ALL_FEATURES"</code>. This completes the change.</p> <p>After you enable all features in your organization, the management account in the organization can apply policies on all member accounts. These policies can restrict what users and even administrators in those accounts can do. The management account can apply policies that prevent accounts from leaving the organization. Ensure that your account administrators are aware of this.</p> <p>This operation can be called only from the organization's management account.</p>
async fn enable_all_features(
&self,
) -> Result<EnableAllFeaturesResponse, RusotoError<EnableAllFeaturesError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.EnableAllFeatures",
);
request.set_payload(Some(bytes::Bytes::from_static(b"{}")));
let response = self
.sign_and_dispatch(request, EnableAllFeaturesError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<EnableAllFeaturesResponse, _>()
}
/// <p>Enables a policy type in a root. After you enable a policy type in a root, you can attach policies of that type to the root, any organizational unit (OU), or account in that root. You can undo this by using the <a>DisablePolicyType</a> operation.</p> <p>This is an asynchronous request that AWS performs in the background. AWS recommends that you first use <a>ListRoots</a> to see the status of policy types for a specified root, and then use this operation.</p> <p>This operation can be called only from the organization's management account.</p> <p>You can enable a policy type in a root only if that policy type is available in the organization. To view the status of available policy types in the organization, use <a>DescribeOrganization</a>.</p>
async fn enable_policy_type(
&self,
input: EnablePolicyTypeRequest,
) -> Result<EnablePolicyTypeResponse, RusotoError<EnablePolicyTypeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.EnablePolicyType");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, EnablePolicyTypeError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<EnablePolicyTypeResponse, _>()
}
/// <p>Sends an invitation to another account to join your organization as a member account. AWS Organizations sends email on your behalf to the email address that is associated with the other account's owner. The invitation is implemented as a <a>Handshake</a> whose details are in the response.</p> <important> <ul> <li> <p>You can invite AWS accounts only from the same seller as the management account. For example, if your organization's management account was created by Amazon Internet Services Pvt. Ltd (AISPL), an AWS seller in India, you can invite only other AISPL accounts to your organization. You can't combine accounts from AISPL and AWS or from any other AWS seller. For more information, see <a href="http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/useconsolidatedbilliing-India.html">Consolidated Billing in India</a>.</p> </li> <li> <p>If you receive an exception that indicates that you exceeded your account limits for the organization or that the operation failed because your organization is still initializing, wait one hour and then try again. If the error persists after an hour, contact <a href="https://console.aws.amazon.com/support/home#/">AWS Support</a>.</p> </li> </ul> </important> <p>If the request includes tags, then the requester must have the <code>organizations:TagResource</code> permission.</p> <p>This operation can be called only from the organization's management account.</p>
async fn invite_account_to_organization(
&self,
input: InviteAccountToOrganizationRequest,
) -> Result<InviteAccountToOrganizationResponse, RusotoError<InviteAccountToOrganizationError>>
{
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.InviteAccountToOrganization",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, InviteAccountToOrganizationError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<InviteAccountToOrganizationResponse, _>()
}
/// <p><p>Removes a member account from its parent organization. This version of the operation is performed by the account that wants to leave. To remove a member account as a user in the management account, use <a>RemoveAccountFromOrganization</a> instead.</p> <p>This operation can be called only from a member account in the organization.</p> <important> <ul> <li> <p>The management account in an organization with all features enabled can set service control policies (SCPs) that can restrict what administrators of member accounts can do. This includes preventing them from successfully calling <code>LeaveOrganization</code> and leaving the organization.</p> </li> <li> <p>You can leave an organization as a member account only if the account is configured with the information required to operate as a standalone account. When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required of standalone accounts is <i>not</i> automatically collected. For each account that you want to make standalone, you must perform the following steps. If any of the steps are already completed for this account, that step doesn't appear.</p> <ul> <li> <p>Choose a support plan</p> </li> <li> <p>Provide and verify the required contact information</p> </li> <li> <p>Provide a current payment method</p> </li> </ul> <p>AWS uses the payment method to charge for any billable (not free tier) AWS activity that occurs while the account isn't attached to an organization. Follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>The account that you want to leave must not be a delegated administrator account for any AWS service enabled for your organization. If the account is a delegated administrator, you must first change the delegated administrator account to another account that is remaining in the organization.</p> </li> <li> <p>You can leave an organization only after you enable IAM user access to billing in your account. For more information, see <a href="http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html#ControllingAccessWebsite-Activate">Activating Access to the Billing and Cost Management Console</a> in the <i>AWS Billing and Cost Management User Guide.</i> </p> </li> <li> <p>After the account leaves the organization, all tags that were attached to the account object in the organization are deleted. AWS accounts outside of an organization do not support tags.</p> </li> <li> <p>A newly created account has a waiting period before it can be removed from its organization. If you get an error that indicates that a wait period is required, then try again in a few days.</p> </li> </ul> </important></p>
async fn leave_organization(&self) -> Result<(), RusotoError<LeaveOrganizationError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.LeaveOrganization",
);
request.set_payload(Some(bytes::Bytes::from_static(b"{}")));
let response = self
.sign_and_dispatch(request, LeaveOrganizationError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Returns a list of the AWS services that you enabled to integrate with your organization. After a service on this list creates the resources that it requires for the integration, it can perform operations on your organization and its accounts.</p> <p>For more information about integrating other services with AWS Organizations, including the list of services that currently work with Organizations, see <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html">Integrating AWS Organizations with Other AWS Services</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_aws_service_access_for_organization(
&self,
input: ListAWSServiceAccessForOrganizationRequest,
) -> Result<
ListAWSServiceAccessForOrganizationResponse,
RusotoError<ListAWSServiceAccessForOrganizationError>,
> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListAWSServiceAccessForOrganization",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(
request,
ListAWSServiceAccessForOrganizationError::from_response,
)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListAWSServiceAccessForOrganizationResponse, _>()
}
/// <p>Lists all the accounts in the organization. To request only the accounts in a specified root or organizational unit (OU), use the <a>ListAccountsForParent</a> operation instead.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_accounts(
&self,
input: ListAccountsRequest,
) -> Result<ListAccountsResponse, RusotoError<ListAccountsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.ListAccounts");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListAccountsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListAccountsResponse, _>()
}
/// <p>Lists the accounts in an organization that are contained by the specified target root or organizational unit (OU). If you specify the root, you get a list of all the accounts that aren't in any OU. If you specify an OU, you get a list of all the accounts in only that OU and not in any child OUs. To get a list of all accounts in the organization, use the <a>ListAccounts</a> operation.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_accounts_for_parent(
&self,
input: ListAccountsForParentRequest,
) -> Result<ListAccountsForParentResponse, RusotoError<ListAccountsForParentError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListAccountsForParent",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListAccountsForParentError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListAccountsForParentResponse, _>()
}
/// <p>Lists all of the organizational units (OUs) or accounts that are contained in the specified parent OU or root. This operation, along with <a>ListParents</a> enables you to traverse the tree structure that makes up this root.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_children(
&self,
input: ListChildrenRequest,
) -> Result<ListChildrenResponse, RusotoError<ListChildrenError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.ListChildren");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListChildrenError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListChildrenResponse, _>()
}
/// <p>Lists the account creation requests that match the specified status that is currently being tracked for the organization.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_create_account_status(
&self,
input: ListCreateAccountStatusRequest,
) -> Result<ListCreateAccountStatusResponse, RusotoError<ListCreateAccountStatusError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListCreateAccountStatus",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListCreateAccountStatusError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListCreateAccountStatusResponse, _>()
}
/// <p>Lists the AWS accounts that are designated as delegated administrators in this organization.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_delegated_administrators(
&self,
input: ListDelegatedAdministratorsRequest,
) -> Result<ListDelegatedAdministratorsResponse, RusotoError<ListDelegatedAdministratorsError>>
{
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListDelegatedAdministrators",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListDelegatedAdministratorsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListDelegatedAdministratorsResponse, _>()
}
/// <p>List the AWS services for which the specified account is a delegated administrator.</p> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_delegated_services_for_account(
&self,
input: ListDelegatedServicesForAccountRequest,
) -> Result<
ListDelegatedServicesForAccountResponse,
RusotoError<ListDelegatedServicesForAccountError>,
> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListDelegatedServicesForAccount",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListDelegatedServicesForAccountError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListDelegatedServicesForAccountResponse, _>()
}
/// <p>Lists the current handshakes that are associated with the account of the requesting user.</p> <p>Handshakes that are <code>ACCEPTED</code>, <code>DECLINED</code>, or <code>CANCELED</code> appear in the results of this API for only 30 days after changing to that state. After that, they're deleted and no longer accessible.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called from any account in the organization.</p>
async fn list_handshakes_for_account(
&self,
input: ListHandshakesForAccountRequest,
) -> Result<ListHandshakesForAccountResponse, RusotoError<ListHandshakesForAccountError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListHandshakesForAccount",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListHandshakesForAccountError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListHandshakesForAccountResponse, _>()
}
/// <p>Lists the handshakes that are associated with the organization that the requesting user is part of. The <code>ListHandshakesForOrganization</code> operation returns a list of handshake structures. Each structure contains details and status about a handshake.</p> <p>Handshakes that are <code>ACCEPTED</code>, <code>DECLINED</code>, or <code>CANCELED</code> appear in the results of this API for only 30 days after changing to that state. After that, they're deleted and no longer accessible.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_handshakes_for_organization(
&self,
input: ListHandshakesForOrganizationRequest,
) -> Result<
ListHandshakesForOrganizationResponse,
RusotoError<ListHandshakesForOrganizationError>,
> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListHandshakesForOrganization",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListHandshakesForOrganizationError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListHandshakesForOrganizationResponse, _>()
}
/// <p>Lists the organizational units (OUs) in a parent organizational unit or root.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_organizational_units_for_parent(
&self,
input: ListOrganizationalUnitsForParentRequest,
) -> Result<
ListOrganizationalUnitsForParentResponse,
RusotoError<ListOrganizationalUnitsForParentError>,
> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListOrganizationalUnitsForParent",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(
request,
ListOrganizationalUnitsForParentError::from_response,
)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListOrganizationalUnitsForParentResponse, _>()
}
/// <p><p>Lists the root or organizational units (OUs) that serve as the immediate parent of the specified child OU or account. This operation, along with <a>ListChildren</a> enables you to traverse the tree structure that makes up this root.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p> <note> <p>In the current release, a child can have only a single parent.</p> </note></p>
async fn list_parents(
&self,
input: ListParentsRequest,
) -> Result<ListParentsResponse, RusotoError<ListParentsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.ListParents");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListParentsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListParentsResponse, _>()
}
/// <p>Retrieves the list of all policies in an organization of a specified type.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_policies(
&self,
input: ListPoliciesRequest,
) -> Result<ListPoliciesResponse, RusotoError<ListPoliciesError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.ListPolicies");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListPoliciesError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListPoliciesResponse, _>()
}
/// <p>Lists the policies that are directly attached to the specified target root, organizational unit (OU), or account. You must specify the policy type that you want included in the returned list.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_policies_for_target(
&self,
input: ListPoliciesForTargetRequest,
) -> Result<ListPoliciesForTargetResponse, RusotoError<ListPoliciesForTargetError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListPoliciesForTarget",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListPoliciesForTargetError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListPoliciesForTargetResponse, _>()
}
/// <p><p>Lists the roots that are defined in the current organization.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p> <note> <p>Policy types can be enabled and disabled in roots. This is distinct from whether they're available in the organization. When you enable all features, you make policy types available for use in that organization. Individual policy types can then be enabled and disabled in a root. To see the availability of a policy type in an organization, use <a>DescribeOrganization</a>.</p> </note></p>
async fn list_roots(
&self,
input: ListRootsRequest,
) -> Result<ListRootsResponse, RusotoError<ListRootsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.ListRoots");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListRootsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListRootsResponse, _>()
}
/// <p>Lists tags that are attached to the specified resource.</p> <p>You can attach tags to the following resources in AWS Organizations.</p> <ul> <li> <p>AWS account</p> </li> <li> <p>Organization root</p> </li> <li> <p>Organizational unit (OU)</p> </li> <li> <p>Policy (any type)</p> </li> </ul> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_tags_for_resource(
&self,
input: ListTagsForResourceRequest,
) -> Result<ListTagsForResourceResponse, RusotoError<ListTagsForResourceError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListTagsForResource",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListTagsForResourceError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListTagsForResourceResponse, _>()
}
/// <p>Lists all the roots, organizational units (OUs), and accounts that the specified policy is attached to.</p> <note> <p>Always check the <code>NextToken</code> response parameter for a <code>null</code> value when calling a <code>List*</code> operation. These operations can occasionally return an empty set of results even when there are more results available. The <code>NextToken</code> response parameter value is <code>null</code> <i>only</i> when there are no more results to display.</p> </note> <p>This operation can be called only from the organization's management account or by a member account that is a delegated administrator for an AWS service.</p>
async fn list_targets_for_policy(
&self,
input: ListTargetsForPolicyRequest,
) -> Result<ListTargetsForPolicyResponse, RusotoError<ListTargetsForPolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.ListTargetsForPolicy",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListTargetsForPolicyError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListTargetsForPolicyResponse, _>()
}
/// <p>Moves an account from its current source parent root or organizational unit (OU) to the specified destination parent root or OU.</p> <p>This operation can be called only from the organization's management account.</p>
async fn move_account(
&self,
input: MoveAccountRequest,
) -> Result<(), RusotoError<MoveAccountError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.MoveAccount");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, MoveAccountError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Enables the specified member account to administer the Organizations features of the specified AWS service. It grants read-only access to AWS Organizations service data. The account still requires IAM permissions to access and administer the AWS service.</p> <p>You can run this action only for AWS services that support this feature. For a current list of services that support it, see the column <i>Supports Delegated Administrator</i> in the table at <a href="https://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services_list.html">AWS Services that you can use with AWS Organizations</a> in the <i>AWS Organizations User Guide.</i> </p> <p>This operation can be called only from the organization's management account.</p>
async fn register_delegated_administrator(
&self,
input: RegisterDelegatedAdministratorRequest,
) -> Result<(), RusotoError<RegisterDelegatedAdministratorError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.RegisterDelegatedAdministrator",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, RegisterDelegatedAdministratorError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p><p>Removes the specified account from the organization.</p> <p>The removed account becomes a standalone account that isn't a member of any organization. It's no longer subject to any policies and is responsible for its own bill payments. The organization's management account is no longer charged for any expenses accrued by the member account after it's removed from the organization.</p> <p>This operation can be called only from the organization's management account. Member accounts can remove themselves with <a>LeaveOrganization</a> instead.</p> <important> <ul> <li> <p>You can remove an account from your organization only if the account is configured with the information required to operate as a standalone account. When you create an account in an organization using the AWS Organizations console, API, or CLI commands, the information required of standalone accounts is <i>not</i> automatically collected. For an account that you want to make standalone, you must choose a support plan, provide and verify the required contact information, and provide a current payment method. AWS uses the payment method to charge for any billable (not free tier) AWS activity that occurs while the account isn't attached to an organization. To remove an account that doesn't yet have this information, you must sign in as the member account and follow the steps at <a href="http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info"> To leave an organization when all required account information has not yet been provided</a> in the <i>AWS Organizations User Guide.</i> </p> </li> <li> <p>The account that you want to leave must not be a delegated administrator account for any AWS service enabled for your organization. If the account is a delegated administrator, you must first change the delegated administrator account to another account that is remaining in the organization.</p> </li> <li> <p>After the account leaves the organization, all tags that were attached to the account object in the organization are deleted. AWS accounts outside of an organization do not support tags.</p> </li> </ul> </important></p>
async fn remove_account_from_organization(
&self,
input: RemoveAccountFromOrganizationRequest,
) -> Result<(), RusotoError<RemoveAccountFromOrganizationError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.RemoveAccountFromOrganization",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, RemoveAccountFromOrganizationError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Adds one or more tags to the specified resource.</p> <p>Currently, you can attach tags to the following resources in AWS Organizations.</p> <ul> <li> <p>AWS account</p> </li> <li> <p>Organization root</p> </li> <li> <p>Organizational unit (OU)</p> </li> <li> <p>Policy (any type)</p> </li> </ul> <p>This operation can be called only from the organization's management account.</p>
async fn tag_resource(
&self,
input: TagResourceRequest,
) -> Result<(), RusotoError<TagResourceError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.TagResource");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, TagResourceError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Removes any tags with the specified keys from the specified resource.</p> <p>You can attach tags to the following resources in AWS Organizations.</p> <ul> <li> <p>AWS account</p> </li> <li> <p>Organization root</p> </li> <li> <p>Organizational unit (OU)</p> </li> <li> <p>Policy (any type)</p> </li> </ul> <p>This operation can be called only from the organization's management account.</p>
async fn untag_resource(
&self,
input: UntagResourceRequest,
) -> Result<(), RusotoError<UntagResourceError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.UntagResource");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, UntagResourceError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
/// <p>Renames the specified organizational unit (OU). The ID and ARN don't change. The child OUs and accounts remain in place, and any attached policies of the OU remain attached.</p> <p>This operation can be called only from the organization's management account.</p>
async fn update_organizational_unit(
&self,
input: UpdateOrganizationalUnitRequest,
) -> Result<UpdateOrganizationalUnitResponse, RusotoError<UpdateOrganizationalUnitError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"AWSOrganizationsV20161128.UpdateOrganizationalUnit",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, UpdateOrganizationalUnitError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<UpdateOrganizationalUnitResponse, _>()
}
/// <p>Updates an existing policy with a new name, description, or content. If you don't supply any parameter, that value remains unchanged. You can't change a policy's type.</p> <p>This operation can be called only from the organization's management account.</p>
async fn update_policy(
&self,
input: UpdatePolicyRequest,
) -> Result<UpdatePolicyResponse, RusotoError<UpdatePolicyError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "AWSOrganizationsV20161128.UpdatePolicy");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, UpdatePolicyError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<UpdatePolicyResponse, _>()
}
}