CEC-749 Generate cert UI (#141)

* Add Create Certificate page

* Tests

* Update permission check

* Use Azure
This commit is contained in:
John Wu
2022-04-18 16:50:51 -07:00
committed by GitHub
parent 81aeedc521
commit 56bef0c34d
28 changed files with 2449 additions and 289 deletions

View File

@@ -0,0 +1,17 @@
import { getAuthHeaderOptions, fetchRespHandler } from "../utils/http";
const API_ENDPOINT = process.env.REACT_APP_CERT_SERVICE_URL;
const certificatesAPI = {
create: async (data, token) =>
fetch(`${API_ENDPOINT}/create`, {
method: "POST",
headers: Object.assign(
{ "Content-Type": "application/json" },
getAuthHeaderOptions(token)
),
body: JSON.stringify(data),
}).then(fetchRespHandler),
};
export default certificatesAPI;