|
284 | 284 | }, |
285 | 285 | "CertCheckResponse": { |
286 | 286 | "properties": { |
| 287 | + "certCheck": { |
| 288 | + "$ref": "#/components/schemas/CertCheckChildResponse" |
| 289 | + }, |
287 | 290 | "certChecks": { |
288 | 291 | "items": { |
289 | 292 | "$ref": "#/components/schemas/CertCheckChildResponse" |
|
303 | 306 | ], |
304 | 307 | "type": "object" |
305 | 308 | }, |
| 309 | + "CheckArrayError": { |
| 310 | + "items": { |
| 311 | + "type": "string" |
| 312 | + }, |
| 313 | + "type": "array" |
| 314 | + }, |
| 315 | + "CheckObjectError": { |
| 316 | + "additionalProperties": { |
| 317 | + "items": { |
| 318 | + "type": "string" |
| 319 | + }, |
| 320 | + "type": "array" |
| 321 | + }, |
| 322 | + "type": "object" |
| 323 | + }, |
306 | 324 | "CreateAlertConfigReceiverPayload": { |
307 | 325 | "description": "Receivers", |
308 | 326 | "properties": { |
|
1774 | 1792 | }, |
1775 | 1793 | "HttpCheckResponse": { |
1776 | 1794 | "properties": { |
| 1795 | + "httpCheck": { |
| 1796 | + "$ref": "#/components/schemas/HttpCheckChildResponse" |
| 1797 | + }, |
1777 | 1798 | "httpChecks": { |
1778 | 1799 | "items": { |
1779 | 1800 | "$ref": "#/components/schemas/HttpCheckChildResponse" |
|
7805 | 7826 | } |
7806 | 7827 | } |
7807 | 7828 | }, |
7808 | | - "description": "Get all cert checks" |
| 7829 | + "description": "Get all cert checks." |
| 7830 | + }, |
| 7831 | + "400": { |
| 7832 | + "content": { |
| 7833 | + "application/json": { |
| 7834 | + "example": [ |
| 7835 | + "instance is not ready" |
| 7836 | + ], |
| 7837 | + "schema": { |
| 7838 | + "$ref": "#/components/schemas/CheckArrayError" |
| 7839 | + } |
| 7840 | + } |
| 7841 | + }, |
| 7842 | + "description": "Something went wrong." |
7809 | 7843 | }, |
7810 | 7844 | "403": { |
7811 | 7845 | "content": { |
|
7818 | 7852 | } |
7819 | 7853 | } |
7820 | 7854 | }, |
7821 | | - "description": "You are not authorized" |
| 7855 | + "description": "You are not authorized." |
7822 | 7856 | } |
7823 | 7857 | }, |
7824 | 7858 | "x-stackit-authorization": { |
|
7866 | 7900 | "content": { |
7867 | 7901 | "application/json": { |
7868 | 7902 | "example": { |
| 7903 | + "certCheck": { |
| 7904 | + "id": "bedcfb8ce34aafd00d7b7b09bca37edc", |
| 7905 | + "source": "tcp://example.org:80" |
| 7906 | + }, |
7869 | 7907 | "certChecks": [ |
7870 | 7908 | { |
7871 | 7909 | "id": "cdb25317a9cdd3e640ed72d432cde7ea", |
7872 | 7910 | "source": "tcp://example.org:443" |
| 7911 | + }, |
| 7912 | + { |
| 7913 | + "id": "bedcfb8ce34aafd00d7b7b09bca37edc", |
| 7914 | + "source": "tcp://example.org:80" |
7873 | 7915 | } |
7874 | 7916 | ], |
7875 | | - "message": "Successfully got all cert checks" |
| 7917 | + "message": "Successfully created cert check" |
7876 | 7918 | }, |
7877 | 7919 | "schema": { |
7878 | 7920 | "$ref": "#/components/schemas/CertCheckResponse" |
7879 | 7921 | } |
7880 | 7922 | } |
7881 | 7923 | }, |
7882 | | - "description": "Get all cert checks" |
| 7924 | + "description": "Get added check (certCheck) and all configured checks (certChecks)." |
| 7925 | + }, |
| 7926 | + "400": { |
| 7927 | + "content": { |
| 7928 | + "application/json": { |
| 7929 | + "examples": { |
| 7930 | + "CheckArrayError": { |
| 7931 | + "summary": "Global error", |
| 7932 | + "value": [ |
| 7933 | + "instance is not ready" |
| 7934 | + ] |
| 7935 | + }, |
| 7936 | + "CheckObjectError": { |
| 7937 | + "summary": "Field specific error", |
| 7938 | + "value": { |
| 7939 | + "source": [ |
| 7940 | + "This field may not be blank." |
| 7941 | + ] |
| 7942 | + } |
| 7943 | + } |
| 7944 | + }, |
| 7945 | + "schema": { |
| 7946 | + "oneOf": [ |
| 7947 | + { |
| 7948 | + "$ref": "#/components/schemas/CheckObjectError" |
| 7949 | + }, |
| 7950 | + { |
| 7951 | + "$ref": "#/components/schemas/CheckArrayError" |
| 7952 | + } |
| 7953 | + ] |
| 7954 | + } |
| 7955 | + } |
| 7956 | + }, |
| 7957 | + "description": "Something went wrong." |
7883 | 7958 | }, |
7884 | 7959 | "403": { |
7885 | 7960 | "content": { |
|
7892 | 7967 | } |
7893 | 7968 | } |
7894 | 7969 | }, |
7895 | | - "description": "You are not authorized" |
| 7970 | + "description": "You are not authorized." |
7896 | 7971 | } |
7897 | 7972 | }, |
7898 | 7973 | "x-stackit-authorization": { |
|
7953 | 8028 | } |
7954 | 8029 | } |
7955 | 8030 | }, |
7956 | | - "description": "Delete cert check" |
| 8031 | + "description": "Delete cert check." |
7957 | 8032 | }, |
7958 | | - "403": { |
| 8033 | + "400": { |
7959 | 8034 | "content": { |
7960 | 8035 | "application/json": { |
7961 | | - "example": { |
7962 | | - "detail": "You do not have permission to perform this action." |
7963 | | - }, |
| 8036 | + "example": [ |
| 8037 | + "instance is not ready" |
| 8038 | + ], |
7964 | 8039 | "schema": { |
7965 | | - "$ref": "#/components/schemas/PermissionDenied" |
| 8040 | + "$ref": "#/components/schemas/CheckArrayError" |
7966 | 8041 | } |
7967 | 8042 | } |
7968 | 8043 | }, |
7969 | | - "description": "You are not authorized" |
| 8044 | + "description": "Something went wrong." |
7970 | 8045 | }, |
7971 | | - "404": { |
| 8046 | + "403": { |
7972 | 8047 | "content": { |
7973 | 8048 | "application/json": { |
7974 | 8049 | "example": { |
7975 | | - "message": "Cert check not found" |
| 8050 | + "detail": "You do not have permission to perform this action." |
7976 | 8051 | }, |
7977 | 8052 | "schema": { |
7978 | | - "$ref": "#/components/schemas/Message" |
| 8053 | + "$ref": "#/components/schemas/PermissionDenied" |
7979 | 8054 | } |
7980 | 8055 | } |
7981 | 8056 | }, |
7982 | | - "description": "Did not found cert check" |
| 8057 | + "description": "You are not authorized." |
7983 | 8058 | } |
7984 | 8059 | }, |
7985 | 8060 | "x-stackit-authorization": { |
|
8821 | 8896 | "url": "https://example.org" |
8822 | 8897 | } |
8823 | 8898 | ], |
8824 | | - "message": "Successfully got all check check urls" |
| 8899 | + "message": "Successfully got all http checks" |
8825 | 8900 | }, |
8826 | 8901 | "schema": { |
8827 | 8902 | "$ref": "#/components/schemas/HttpCheckResponse" |
8828 | 8903 | } |
8829 | 8904 | } |
8830 | 8905 | }, |
8831 | | - "description": "Get all http checks" |
| 8906 | + "description": "Get all http checks." |
| 8907 | + }, |
| 8908 | + "400": { |
| 8909 | + "content": { |
| 8910 | + "application/json": { |
| 8911 | + "example": [ |
| 8912 | + "instance is not ready" |
| 8913 | + ], |
| 8914 | + "schema": { |
| 8915 | + "$ref": "#/components/schemas/CheckArrayError" |
| 8916 | + } |
| 8917 | + } |
| 8918 | + }, |
| 8919 | + "description": "Something went wrong." |
8832 | 8920 | }, |
8833 | 8921 | "403": { |
8834 | 8922 | "content": { |
|
8841 | 8929 | } |
8842 | 8930 | } |
8843 | 8931 | }, |
8844 | | - "description": "You are not authorized" |
| 8932 | + "description": "You are not authorized." |
8845 | 8933 | } |
8846 | 8934 | }, |
8847 | 8935 | "x-stackit-authorization": { |
|
8889 | 8977 | "content": { |
8890 | 8978 | "application/json": { |
8891 | 8979 | "example": { |
| 8980 | + "httpCheck": { |
| 8981 | + "id": "8cb80949d33b768d4ef61f94f3f54cba", |
| 8982 | + "url": "https://example-2.org" |
| 8983 | + }, |
8892 | 8984 | "httpChecks": [ |
8893 | 8985 | { |
8894 | 8986 | "id": "5564fd6a95028f02e52b38bb1743c816", |
8895 | 8987 | "url": "https://example.org" |
| 8988 | + }, |
| 8989 | + { |
| 8990 | + "id": "8cb80949d33b768d4ef61f94f3f54cba", |
| 8991 | + "url": "https://example-2.org" |
8896 | 8992 | } |
8897 | 8993 | ], |
8898 | | - "message": "Successfully got all check check urls" |
| 8994 | + "message": "Successfully created http check" |
8899 | 8995 | }, |
8900 | 8996 | "schema": { |
8901 | 8997 | "$ref": "#/components/schemas/HttpCheckResponse" |
8902 | 8998 | } |
8903 | 8999 | } |
8904 | 9000 | }, |
8905 | | - "description": "Get all http checks" |
| 9001 | + "description": "Get added check (httpCheck) and all configured checks (httpChecks)." |
| 9002 | + }, |
| 9003 | + "400": { |
| 9004 | + "content": { |
| 9005 | + "application/json": { |
| 9006 | + "examples": { |
| 9007 | + "CheckArrayError": { |
| 9008 | + "summary": "Global error", |
| 9009 | + "value": [ |
| 9010 | + "instance is not ready" |
| 9011 | + ] |
| 9012 | + }, |
| 9013 | + "CheckObjectError": { |
| 9014 | + "summary": "Field specific error", |
| 9015 | + "value": { |
| 9016 | + "url": [ |
| 9017 | + "This field may not be blank." |
| 9018 | + ] |
| 9019 | + } |
| 9020 | + } |
| 9021 | + }, |
| 9022 | + "schema": { |
| 9023 | + "oneOf": [ |
| 9024 | + { |
| 9025 | + "$ref": "#/components/schemas/CheckObjectError" |
| 9026 | + }, |
| 9027 | + { |
| 9028 | + "$ref": "#/components/schemas/CheckArrayError" |
| 9029 | + } |
| 9030 | + ] |
| 9031 | + } |
| 9032 | + } |
| 9033 | + }, |
| 9034 | + "description": "Something went wrong." |
8906 | 9035 | }, |
8907 | 9036 | "403": { |
8908 | 9037 | "content": { |
|
8915 | 9044 | } |
8916 | 9045 | } |
8917 | 9046 | }, |
8918 | | - "description": "You are not authorized" |
| 9047 | + "description": "You are not authorized." |
8919 | 9048 | } |
8920 | 9049 | }, |
8921 | 9050 | "x-stackit-authorization": { |
|
8969 | 9098 | "url": "https://example.org" |
8970 | 9099 | } |
8971 | 9100 | ], |
8972 | | - "message": "Successfully deleted ping check urls" |
| 9101 | + "message": "Successfully deleted http check" |
8973 | 9102 | }, |
8974 | 9103 | "schema": { |
8975 | 9104 | "$ref": "#/components/schemas/HttpCheckResponse" |
8976 | 9105 | } |
8977 | 9106 | } |
8978 | 9107 | }, |
8979 | | - "description": "Delete http check" |
| 9108 | + "description": "Delete http check." |
8980 | 9109 | }, |
8981 | | - "403": { |
| 9110 | + "400": { |
8982 | 9111 | "content": { |
8983 | 9112 | "application/json": { |
8984 | | - "example": { |
8985 | | - "detail": "You do not have permission to perform this action." |
8986 | | - }, |
| 9113 | + "example": [ |
| 9114 | + "instance is not ready" |
| 9115 | + ], |
8987 | 9116 | "schema": { |
8988 | | - "$ref": "#/components/schemas/PermissionDenied" |
| 9117 | + "$ref": "#/components/schemas/CheckArrayError" |
8989 | 9118 | } |
8990 | 9119 | } |
8991 | 9120 | }, |
8992 | | - "description": "You are not authorized" |
| 9121 | + "description": "Something went wrong." |
8993 | 9122 | }, |
8994 | | - "404": { |
| 9123 | + "403": { |
8995 | 9124 | "content": { |
8996 | 9125 | "application/json": { |
8997 | 9126 | "example": { |
8998 | | - "message": "Http check url not found" |
| 9127 | + "detail": "You do not have permission to perform this action." |
8999 | 9128 | }, |
9000 | 9129 | "schema": { |
9001 | | - "$ref": "#/components/schemas/Message" |
| 9130 | + "$ref": "#/components/schemas/PermissionDenied" |
9002 | 9131 | } |
9003 | 9132 | } |
9004 | 9133 | }, |
9005 | | - "description": "Did not found http check" |
| 9134 | + "description": "You are not authorized." |
9006 | 9135 | } |
9007 | 9136 | }, |
9008 | 9137 | "x-stackit-authorization": { |
|
0 commit comments