Skip to content

Commit 80b006a

Browse files
authored
Merge pull request #758 from snowe2010/add-appconfig-query
Add AWS AppConfig API Data Source
2 parents aca33f2 + 846f576 commit 80b006a

File tree

10 files changed

+2196
-1
lines changed

10 files changed

+2196
-1
lines changed

server/api-service/api-examples.http

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
### login?
2+
POST http://localhost:8080/api/auth/form/login
3+
Content-Type: application/json
4+
5+
{
6+
"register": false,
7+
"loginId": "[email protected]",
8+
"password": "test1234",
9+
"source": "EMAIL"
10+
}
11+
12+
### get apps
13+
GET http://localhost:8080/api/applications/list
14+
15+
### Send POST request with json body
16+
POST http://localhost:8080/api/applications
17+
Content-Type: application/json
18+
19+
{
20+
"orgId": "65ea883d248b9d61b5ec8eaf",
21+
"name": "testingapi2",
22+
"appUrlName": "thisIsASlug"
23+
}

server/node-service/package.json

+2
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@
2929
},
3030
"dependencies": {
3131
"@apidevtools/swagger-parser": "^10.1.0",
32+
"@aws-sdk/client-appconfig": "^3.533.0",
33+
"@aws-sdk/client-appconfigdata": "^3.533.0",
3234
"@aws-sdk/client-athena": "^3.333.0",
3335
"@aws-sdk/client-dynamodb": "^3.332.0",
3436
"@aws-sdk/client-lambda": "^3.332.0",
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import { ConfigToType } from "lowcoder-sdk/dataSource";
2+
3+
const dataSourceConfig = {
4+
type: "dataSource",
5+
params: [
6+
{
7+
key: "region",
8+
type: "textInput",
9+
label: "Region",
10+
rules: [{ required: true, message: "Please input the AWS Region" }],
11+
defaultValue: "us-west-1",
12+
},
13+
{
14+
key: "accessKey",
15+
label: "Access key ID",
16+
type: "textInput",
17+
placeholder: "<Your Access key ID>",
18+
rules: [{ required: true, message: "Please input the Access Key ID" }],
19+
},
20+
{
21+
key: "secretKey",
22+
label: "Secret key",
23+
type: "password",
24+
rules: [{ required: true, message: "Please input the Secret Key" }],
25+
},
26+
],
27+
} as const;
28+
29+
export default dataSourceConfig;
30+
31+
export type DataSourceDataType = ConfigToType<typeof dataSourceConfig>;

0 commit comments

Comments
 (0)