Application
Definition
- JSON
- Typescript
application.json
{
"id": 0,
"applicationKey": "",
"applicationName": "",
"applicationDescription": "",
"clientID": "",
"clientSecret": "",
"redirectUri": "",
"status": 0,
"createdAt": "",
"updatedAt": "",
}
application.ts
export interface IApplication {
id: number;
applicationKey: string;
applicationName: string;
applicationDescription: string | null;
clientID: string;
clientSecret: string;
redirectUri: string;
status: number;
createdAt: Date | null;
updatedAt: Date | null;
}
Get Applications
- Curl
- Typescript
curl -X GET "${baseUrl}/application/?filter=${filter}&orderBy=${orderBy}&page=${page}&pageSize=${pageSize}" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json"
const response = await fetch("${baseUrl}/application/?filter=${filter}&orderBy=${orderBy}&page=${page}&pageSize=${pageSize}", {
method: "GET",
headers: {
"Content-Type": "application/json",
"Accept": "application/json",
"Authorization": `Bearer ${accessToken}`,
},
})
const data = await response.json();
if (!response.ok) {
throw new Error(data);
}
Get Application
- Curl
- Typescript
curl -X GET "${baseUrl}/application/${id}" \
-H "Authorization: Bearer ${accessToken}" \
-H "Content-Type: application/json" \
-H "Accept: application/json"