Skip to content

Commit 6abe53d

Browse files
committed
update
1 parent 476dd50 commit 6abe53d

File tree

2 files changed

+3
-11
lines changed

2 files changed

+3
-11
lines changed

components/mintlify/actions/trigger-update/trigger-update.mjs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,19 +13,13 @@ export default {
1313
},
1414
props: {
1515
mintlify,
16-
projectId: {
17-
type: "string",
18-
label: "Project ID",
19-
description: "The ID of the project to trigger an update on. Can be retrieved from your dashboard.",
20-
},
2116
},
2217
async run({ $ }) {
2318
const response = await this.mintlify.triggerUpdate({
24-
projectId: this.projectId,
2519
$,
2620
});
2721

28-
$.export("$summary", `Successfully triggered an update for project ${this.projectId}`);
22+
$.export("$summary", `Successfully triggered an update for project ${this.mintlify.$auth.project_id}`);
2923

3024
return response;
3125
},

components/mintlify/mintlify.app.mjs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,9 @@ export default {
2525
...opts,
2626
});
2727
},
28-
triggerUpdate({
29-
projectId, ...opts
30-
}) {
28+
triggerUpdate(opts = {}) {
3129
return this._makeRequest({
32-
url: `https://api.mintlify.com/v1/project/update/${projectId}`,
30+
url: `https://api.mintlify.com/v1/project/update/${this.$auth.project_id}`,
3331
method: "POST",
3432
headers: {
3533
Authorization: `Bearer ${this.$auth.admin_api_key}`,

0 commit comments

Comments
 (0)