TASK22224: complete documents + endpoint hygiene slices

This commit is contained in:
2026-03-24 06:12:04 +00:00
parent dfdfd3653c
commit fe394f3fa8
6 changed files with 221 additions and 189 deletions
@@ -20,35 +20,6 @@ const WEBAPI_URL =
process.env.RELAY_ROOT ||
"https://dev-pedw-ns.servicebus.windows.net/dev-pedw-hc/";
// export default async function ApiProxy(req, res) {
// var token = await getToken();
// var data = JSON.stringify(req.body);
// var queryUrl = "pinswg_watchlists";
// console.log(data);
// var config = {
// method: "put",
// url: WEBAPI_URL + queryUrl + hashAPIPath(queryUrl),
// headers: {
// "OData-MaxVersion": "4.0",
// "OData-Version": "4.0",
// "Accept": "application/json",
// "Prefer": 'odata.include-annotations="*",return=representation',
// "Authorization": "Bearer " + token.access_token,
// "Content-Type": "application/json",
// },
// data: data,
// };
// return axios(config)
// .then(({ data }) => {
// res.status(200).json(data);
// })
// .catch((error) => {
// consoleLogger(Object.assign(err, data));
// res.status(400).json(error);
// });
// }
const recordExists = async (incidentId, contactId, token) => {
const filter = `$filter=pinswg_WatchedCase/incidentid eq ${incidentId} and pinswg_Contact/contactid eq ${contactId}`;
const queryUrl = `pinswg_watchlists?${filter}`;