@storyblok/schema 0.1.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +8 -0
- package/README.md +74 -0
- package/dist/generated/capi/_internal.gen.d.cts +120 -0
- package/dist/generated/capi/_internal.gen.d.mts +120 -0
- package/dist/generated/capi/types.gen.d.cts +181 -0
- package/dist/generated/capi/types.gen.d.mts +181 -0
- package/dist/generated/mapi/_internal.gen.d.cts +683 -0
- package/dist/generated/mapi/_internal.gen.d.mts +683 -0
- package/dist/generated/mapi/types.gen.d.cts +1272 -0
- package/dist/generated/mapi/types.gen.d.mts +1272 -0
- package/dist/generated/overlay/_internal.gen.d.cts +850 -0
- package/dist/generated/overlay/_internal.gen.d.mts +850 -0
- package/dist/generated/types/_utils.d.cts +7 -0
- package/dist/generated/types/_utils.d.mts +7 -0
- package/dist/generated/types/block.d.cts +46 -0
- package/dist/generated/types/block.d.mts +46 -0
- package/dist/generated/types/field.d.cts +74 -0
- package/dist/generated/types/field.d.mts +74 -0
- package/dist/generated/types/mapi-story.d.cts +29 -0
- package/dist/generated/types/mapi-story.d.mts +29 -0
- package/dist/generated/types/story.d.cts +19 -0
- package/dist/generated/types/story.d.mts +19 -0
- package/dist/helpers/create-story-helpers.cjs +42 -0
- package/dist/helpers/create-story-helpers.cjs.map +1 -0
- package/dist/helpers/create-story-helpers.d.cts +50 -0
- package/dist/helpers/create-story-helpers.d.mts +50 -0
- package/dist/helpers/create-story-helpers.mjs +42 -0
- package/dist/helpers/create-story-helpers.mjs.map +1 -0
- package/dist/helpers/define-asset-folder.cjs +46 -0
- package/dist/helpers/define-asset-folder.cjs.map +1 -0
- package/dist/helpers/define-asset-folder.d.cts +33 -0
- package/dist/helpers/define-asset-folder.d.mts +33 -0
- package/dist/helpers/define-asset-folder.mjs +43 -0
- package/dist/helpers/define-asset-folder.mjs.map +1 -0
- package/dist/helpers/define-asset.cjs +60 -0
- package/dist/helpers/define-asset.cjs.map +1 -0
- package/dist/helpers/define-asset.d.cts +32 -0
- package/dist/helpers/define-asset.d.mts +32 -0
- package/dist/helpers/define-asset.mjs +57 -0
- package/dist/helpers/define-asset.mjs.map +1 -0
- package/dist/helpers/define-block-folder.cjs +44 -0
- package/dist/helpers/define-block-folder.cjs.map +1 -0
- package/dist/helpers/define-block-folder.d.cts +34 -0
- package/dist/helpers/define-block-folder.d.mts +34 -0
- package/dist/helpers/define-block-folder.mjs +41 -0
- package/dist/helpers/define-block-folder.mjs.map +1 -0
- package/dist/helpers/define-block.cjs +51 -0
- package/dist/helpers/define-block.cjs.map +1 -0
- package/dist/helpers/define-block.d.cts +62 -0
- package/dist/helpers/define-block.d.mts +62 -0
- package/dist/helpers/define-block.mjs +48 -0
- package/dist/helpers/define-block.mjs.map +1 -0
- package/dist/helpers/define-datasource-entry.cjs +47 -0
- package/dist/helpers/define-datasource-entry.cjs.map +1 -0
- package/dist/helpers/define-datasource-entry.d.cts +49 -0
- package/dist/helpers/define-datasource-entry.d.mts +49 -0
- package/dist/helpers/define-datasource-entry.mjs +43 -0
- package/dist/helpers/define-datasource-entry.mjs.map +1 -0
- package/dist/helpers/define-datasource.cjs +34 -0
- package/dist/helpers/define-datasource.cjs.map +1 -0
- package/dist/helpers/define-datasource.d.cts +42 -0
- package/dist/helpers/define-datasource.d.mts +42 -0
- package/dist/helpers/define-datasource.mjs +31 -0
- package/dist/helpers/define-datasource.mjs.map +1 -0
- package/dist/helpers/define-field.cjs +17 -0
- package/dist/helpers/define-field.cjs.map +1 -0
- package/dist/helpers/define-field.d.cts +99 -0
- package/dist/helpers/define-field.d.mts +99 -0
- package/dist/helpers/define-field.mjs +16 -0
- package/dist/helpers/define-field.mjs.map +1 -0
- package/dist/helpers/define-internal-tag.cjs +41 -0
- package/dist/helpers/define-internal-tag.cjs.map +1 -0
- package/dist/helpers/define-internal-tag.d.cts +34 -0
- package/dist/helpers/define-internal-tag.d.mts +34 -0
- package/dist/helpers/define-internal-tag.mjs +38 -0
- package/dist/helpers/define-internal-tag.mjs.map +1 -0
- package/dist/helpers/define-link.cjs +23 -0
- package/dist/helpers/define-link.cjs.map +1 -0
- package/dist/helpers/define-link.d.cts +32 -0
- package/dist/helpers/define-link.d.mts +32 -0
- package/dist/helpers/define-link.mjs +22 -0
- package/dist/helpers/define-link.mjs.map +1 -0
- package/dist/helpers/define-preset.cjs +44 -0
- package/dist/helpers/define-preset.cjs.map +1 -0
- package/dist/helpers/define-preset.d.cts +35 -0
- package/dist/helpers/define-preset.d.mts +35 -0
- package/dist/helpers/define-preset.mjs +41 -0
- package/dist/helpers/define-preset.mjs.map +1 -0
- package/dist/helpers/define-space.cjs +47 -0
- package/dist/helpers/define-space.cjs.map +1 -0
- package/dist/helpers/define-space.d.cts +31 -0
- package/dist/helpers/define-space.d.mts +31 -0
- package/dist/helpers/define-space.mjs +44 -0
- package/dist/helpers/define-space.mjs.map +1 -0
- package/dist/helpers/define-story.cjs +122 -0
- package/dist/helpers/define-story.cjs.map +1 -0
- package/dist/helpers/define-story.d.cts +135 -0
- package/dist/helpers/define-story.d.mts +135 -0
- package/dist/helpers/define-story.mjs +118 -0
- package/dist/helpers/define-story.mjs.map +1 -0
- package/dist/helpers/define-tag.cjs +13 -0
- package/dist/helpers/define-tag.cjs.map +1 -0
- package/dist/helpers/define-tag.d.cts +23 -0
- package/dist/helpers/define-tag.d.mts +23 -0
- package/dist/helpers/define-tag.mjs +12 -0
- package/dist/helpers/define-tag.mjs.map +1 -0
- package/dist/helpers/define-user.cjs +50 -0
- package/dist/helpers/define-user.cjs.map +1 -0
- package/dist/helpers/define-user.d.cts +26 -0
- package/dist/helpers/define-user.d.mts +26 -0
- package/dist/helpers/define-user.mjs +48 -0
- package/dist/helpers/define-user.mjs.map +1 -0
- package/dist/helpers/schema-type.d.cts +40 -0
- package/dist/helpers/schema-type.d.mts +40 -0
- package/dist/index.cjs +55 -0
- package/dist/index.d.cts +23 -0
- package/dist/index.d.mts +23 -0
- package/dist/index.mjs +17 -0
- package/dist/utils/prettify.d.cts +9 -0
- package/dist/utils/prettify.d.mts +9 -0
- package/package.json +78 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
Copyright © 2025 Storyblok GmbH
|
|
3
|
+
|
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
5
|
+
|
|
6
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
7
|
+
|
|
8
|
+
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
3
|
+

|
|
4
|
+
|
|
5
|
+
<h1 align="center">@storyblok/schema</h1>
|
|
6
|
+
<p>
|
|
7
|
+
Shared Storyblok schema types generated from the Management and Content API specifications
|
|
8
|
+
</p>
|
|
9
|
+
<br />
|
|
10
|
+
</div>
|
|
11
|
+
|
|
12
|
+
<p align="center">
|
|
13
|
+
<a href="https://npmjs.com/package/@storyblok/schema">
|
|
14
|
+
<img src="https://img.shields.io/npm/v/@storyblok/schema/latest.svg?style=flat-square&color=8d60ff" alt="@storyblok/schema" />
|
|
15
|
+
</a>
|
|
16
|
+
<a href="https://npmjs.com/package/@storyblok/schema" rel="nofollow">
|
|
17
|
+
<img src="https://img.shields.io/npm/dt/@storyblok/schema.svg?style=appveyor&color=8d60ff" alt="npm">
|
|
18
|
+
</a>
|
|
19
|
+
<a href="https://storyblok.com/join-discord">
|
|
20
|
+
<img src="https://img.shields.io/discord/700316478792138842?label=Join%20Our%20Discord%20Community&style=appveyor&logo=discord&color=8d60ff">
|
|
21
|
+
</a>
|
|
22
|
+
<a href="https://twitter.com/intent/follow?screen_name=storyblok">
|
|
23
|
+
<img src="https://img.shields.io/badge/Follow-%40storyblok-8d60ff?style=appveyor&logo=twitter" alt="Follow @Storyblok" />
|
|
24
|
+
</a><br/>
|
|
25
|
+
<a href="https://app.storyblok.com/#!/signup?utm_source=github.com&utm_medium=readme&utm_campaign=@storyblok/schema">
|
|
26
|
+
<img src="https://img.shields.io/badge/Try%20Storyblok-Free-8d60ff?style=appveyor&logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAABGdBTUEAALGPC/xhBQAAADhlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAAqACAAQAAAABAAAAHqADAAQAAAABAAAAHgAAAADpiRU/AAACRElEQVRIDWNgGGmAEd3D3Js3LPrP8D8WXZwSPiMjw6qvPoHhyGYwIXNAbGpbCjbzP0MYuj0YFqMroBV/wCxmIeSju64eDNzMBJUxvP/9i2Hnq5cM1devMnz984eQsQwETeRhYWHgIcJiXqC6VHlFBjUeXgav40cIWkz1oLYXFmGwFBImaDFBHyObcOzdW4aSq5eRhRiE2dgYlpuYoYSKJi8vw3GgWnyAJIs/AuPu4scPGObd/fqVQZ+PHy7+6udPOBsXgySLDfn5GRYYmaKYJcXBgWLpsx8/GPa8foWiBhuHJIsl2DkYQqWksZkDFgP5PObcKYYff//iVAOTIDlx/QPqRMb/YSYBaWlOToZIaVkGZmAZSQiQ5OPtwHwacuo4iplMQEu6tXUZMhSUGDiYmBjylFQYvv/7x9B04xqKOnQOyT5GN+Df//8M59ASXKyMHLoyDD5JPtbj42OYrm+EYgg70JfuYuIoYmLs7AwMjIzA+uY/zjAnyWJpDk6GOFnCvrn86SOwmsNtKciVFAc1ileBHFDC67lzG10Yg0+SjzF0ownsf/OaofvOLYaDQJoQIGix94ljv1gIZI8Pv38zPvj2lQWYf3HGKbpDCFp85v07NnRN1OBTPY6JdRSGxcCw2k6sZuLVMZ5AV4s1TozPnGGFKbz+/PE7IJsHmC//MDMyhXBw8e6FyRFLv3Z0/IKuFqvFyIqAzd1PwBzJw8jAGPfVx38JshwlbIygxmYY43/GQmpais0ODDHuzevLMARHBcgIAQAbOJHZW0/EyQAAAABJRU5ErkJggg==" alt="Follow @Storyblok" />
|
|
27
|
+
</a>
|
|
28
|
+
</p>
|
|
29
|
+
|
|
30
|
+
## Features
|
|
31
|
+
|
|
32
|
+
- **Generated Types**: TypeScript types generated from Storyblok Management and Content API OpenAPI specifications
|
|
33
|
+
- **Shared Schema Layer**: Reuse the same Storyblok content shapes across packages and integrations
|
|
34
|
+
- **Framework Agnostic**: Use the package in any TypeScript project without framework-specific dependencies
|
|
35
|
+
- **Monorepo Aligned**: Built from the same source specifications used throughout the Storyblok monoblok repository
|
|
36
|
+
|
|
37
|
+
## Documentation
|
|
38
|
+
|
|
39
|
+
<!-- TODO: restore docs link once live — https://www.storyblok.com/docs/packages/storyblok-schema (docs #536/#548) -->
|
|
40
|
+
|
|
41
|
+
Full package documentation is coming soon. For now, browse the [package source on GitHub](https://github.com/storyblok/monoblok/tree/alpha/packages/schema) or explore a runnable example in the [Astro playground](https://github.com/storyblok/monoblok/tree/alpha/packages/schema/playground/astro).
|
|
42
|
+
|
|
43
|
+
## Contributing
|
|
44
|
+
|
|
45
|
+
If you'd like to contribute, please refer to the [contributing guidelines](../../CONTRIBUTING.md).
|
|
46
|
+
|
|
47
|
+
## Community
|
|
48
|
+
|
|
49
|
+
For help, discussion about best practices, or any other conversation that would benefit from being searchable:
|
|
50
|
+
|
|
51
|
+
- [Discuss Storyblok on GitHub Discussions](https://github.com/storyblok/monoblok/discussions)
|
|
52
|
+
|
|
53
|
+
For community support, chatting with other users, please visit:
|
|
54
|
+
|
|
55
|
+
- [Discuss Storyblok on Discord](https://storyblok.com/join-discord)
|
|
56
|
+
|
|
57
|
+
## Support
|
|
58
|
+
|
|
59
|
+
For bugs or feature requests, please [submit an issue](https://github.com/storyblok/monoblok/issues/new/choose).
|
|
60
|
+
|
|
61
|
+
> [!IMPORTANT]
|
|
62
|
+
> Please search existing issues before submitting a new one. Issues without a minimal reproducible example will be closed. [Why reproductions are Required](https://antfu.me/posts/why-reproductions-are-required).
|
|
63
|
+
|
|
64
|
+
### I can't share my company project code
|
|
65
|
+
|
|
66
|
+
We understand that you might not be able to share your company's project code. Please provide a minimal reproducible example that demonstrates the issue by using tools like [Stackblitz](https://stackblitz.com) or a link to a GitHub repo. Please make sure you include a README file with the instructions to build and run the project, important not to include any access token, password or personal information of any kind.
|
|
67
|
+
|
|
68
|
+
### Feedback
|
|
69
|
+
|
|
70
|
+
If you have a question, please ask in the [Discuss Storyblok on Discord](https://storyblok.com/join-discord) channel.
|
|
71
|
+
|
|
72
|
+
## License
|
|
73
|
+
|
|
74
|
+
[License](/LICENSE)
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
//#region src/generated/capi/_internal.gen.d.ts
|
|
2
|
+
type CapiStory = ({
|
|
3
|
+
version?: 'draft';
|
|
4
|
+
} & DraftStory) | ({
|
|
5
|
+
version?: 'published';
|
|
6
|
+
} & PublishedStory);
|
|
7
|
+
type DraftStory = {
|
|
8
|
+
name: string;
|
|
9
|
+
/**
|
|
10
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
11
|
+
*/
|
|
12
|
+
created_at: string;
|
|
13
|
+
/**
|
|
14
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
15
|
+
*/
|
|
16
|
+
updated_at?: string | null;
|
|
17
|
+
/**
|
|
18
|
+
* Latest publication timestamp (format is ISO 8601 standard in UTC).
|
|
19
|
+
*/
|
|
20
|
+
published_at: string | null;
|
|
21
|
+
alternates: Array<StoryAlternate>;
|
|
22
|
+
id: number;
|
|
23
|
+
uuid: string;
|
|
24
|
+
/**
|
|
25
|
+
* Dynamic component data rendered by Storyblok, structure varies by component.
|
|
26
|
+
*/
|
|
27
|
+
content: {
|
|
28
|
+
_uid?: string;
|
|
29
|
+
component?: string;
|
|
30
|
+
[key: string]: unknown | string | undefined;
|
|
31
|
+
};
|
|
32
|
+
slug: string;
|
|
33
|
+
full_slug: string;
|
|
34
|
+
default_full_slug: string | null;
|
|
35
|
+
sort_by_date: string | null;
|
|
36
|
+
position: number;
|
|
37
|
+
tag_list: Array<string>;
|
|
38
|
+
is_startpage: boolean;
|
|
39
|
+
parent_id: number;
|
|
40
|
+
/**
|
|
41
|
+
* Custom metadata for the story.
|
|
42
|
+
*/
|
|
43
|
+
meta_data: {
|
|
44
|
+
[key: string]: unknown;
|
|
45
|
+
} | null;
|
|
46
|
+
group_id: string;
|
|
47
|
+
first_published_at: string | null;
|
|
48
|
+
release_id: number | null;
|
|
49
|
+
lang: string;
|
|
50
|
+
path: string | null;
|
|
51
|
+
translated_slugs: Array<{
|
|
52
|
+
path: string;
|
|
53
|
+
name: string | null;
|
|
54
|
+
lang: string;
|
|
55
|
+
published: string | null;
|
|
56
|
+
}> | null;
|
|
57
|
+
};
|
|
58
|
+
type PublishedStory = {
|
|
59
|
+
name: string;
|
|
60
|
+
/**
|
|
61
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
62
|
+
*/
|
|
63
|
+
created_at: string;
|
|
64
|
+
/**
|
|
65
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
66
|
+
*/
|
|
67
|
+
updated_at?: string | null;
|
|
68
|
+
/**
|
|
69
|
+
* Latest publication timestamp (format is ISO 8601 standard in UTC).
|
|
70
|
+
*/
|
|
71
|
+
published_at: string | null;
|
|
72
|
+
id: number;
|
|
73
|
+
uuid: string;
|
|
74
|
+
/**
|
|
75
|
+
* Dynamic component data rendered by Storyblok, structure varies by component.
|
|
76
|
+
*/
|
|
77
|
+
content: {
|
|
78
|
+
_uid?: string;
|
|
79
|
+
component?: string;
|
|
80
|
+
[key: string]: unknown | string | undefined;
|
|
81
|
+
};
|
|
82
|
+
slug: string;
|
|
83
|
+
full_slug: string;
|
|
84
|
+
sort_by_date: string | null;
|
|
85
|
+
position: number;
|
|
86
|
+
tag_list: Array<string>;
|
|
87
|
+
is_startpage: boolean;
|
|
88
|
+
parent_id: number;
|
|
89
|
+
/**
|
|
90
|
+
* Custom metadata for the story.
|
|
91
|
+
*/
|
|
92
|
+
meta_data: {
|
|
93
|
+
[key: string]: unknown;
|
|
94
|
+
} | null;
|
|
95
|
+
group_id: string;
|
|
96
|
+
first_published_at: string | null;
|
|
97
|
+
release_id?: number | null;
|
|
98
|
+
lang: string;
|
|
99
|
+
path: string | null;
|
|
100
|
+
alternates: Array<StoryAlternate>;
|
|
101
|
+
default_full_slug: string | null;
|
|
102
|
+
translated_slugs: Array<{
|
|
103
|
+
path: string;
|
|
104
|
+
name: string | null;
|
|
105
|
+
lang: string;
|
|
106
|
+
published: string | null;
|
|
107
|
+
}> | null;
|
|
108
|
+
};
|
|
109
|
+
type StoryAlternate = {
|
|
110
|
+
id: number;
|
|
111
|
+
name: string;
|
|
112
|
+
slug: string;
|
|
113
|
+
published: boolean | null;
|
|
114
|
+
full_slug: string;
|
|
115
|
+
is_folder: boolean;
|
|
116
|
+
parent_id: number;
|
|
117
|
+
};
|
|
118
|
+
//#endregion
|
|
119
|
+
export { CapiStory };
|
|
120
|
+
//# sourceMappingURL=_internal.gen.d.cts.map
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
//#region src/generated/capi/_internal.gen.d.ts
|
|
2
|
+
type CapiStory = ({
|
|
3
|
+
version?: 'draft';
|
|
4
|
+
} & DraftStory) | ({
|
|
5
|
+
version?: 'published';
|
|
6
|
+
} & PublishedStory);
|
|
7
|
+
type DraftStory = {
|
|
8
|
+
name: string;
|
|
9
|
+
/**
|
|
10
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
11
|
+
*/
|
|
12
|
+
created_at: string;
|
|
13
|
+
/**
|
|
14
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
15
|
+
*/
|
|
16
|
+
updated_at?: string | null;
|
|
17
|
+
/**
|
|
18
|
+
* Latest publication timestamp (format is ISO 8601 standard in UTC).
|
|
19
|
+
*/
|
|
20
|
+
published_at: string | null;
|
|
21
|
+
alternates: Array<StoryAlternate>;
|
|
22
|
+
id: number;
|
|
23
|
+
uuid: string;
|
|
24
|
+
/**
|
|
25
|
+
* Dynamic component data rendered by Storyblok, structure varies by component.
|
|
26
|
+
*/
|
|
27
|
+
content: {
|
|
28
|
+
_uid?: string;
|
|
29
|
+
component?: string;
|
|
30
|
+
[key: string]: unknown | string | undefined;
|
|
31
|
+
};
|
|
32
|
+
slug: string;
|
|
33
|
+
full_slug: string;
|
|
34
|
+
default_full_slug: string | null;
|
|
35
|
+
sort_by_date: string | null;
|
|
36
|
+
position: number;
|
|
37
|
+
tag_list: Array<string>;
|
|
38
|
+
is_startpage: boolean;
|
|
39
|
+
parent_id: number;
|
|
40
|
+
/**
|
|
41
|
+
* Custom metadata for the story.
|
|
42
|
+
*/
|
|
43
|
+
meta_data: {
|
|
44
|
+
[key: string]: unknown;
|
|
45
|
+
} | null;
|
|
46
|
+
group_id: string;
|
|
47
|
+
first_published_at: string | null;
|
|
48
|
+
release_id: number | null;
|
|
49
|
+
lang: string;
|
|
50
|
+
path: string | null;
|
|
51
|
+
translated_slugs: Array<{
|
|
52
|
+
path: string;
|
|
53
|
+
name: string | null;
|
|
54
|
+
lang: string;
|
|
55
|
+
published: string | null;
|
|
56
|
+
}> | null;
|
|
57
|
+
};
|
|
58
|
+
type PublishedStory = {
|
|
59
|
+
name: string;
|
|
60
|
+
/**
|
|
61
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
62
|
+
*/
|
|
63
|
+
created_at: string;
|
|
64
|
+
/**
|
|
65
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
66
|
+
*/
|
|
67
|
+
updated_at?: string | null;
|
|
68
|
+
/**
|
|
69
|
+
* Latest publication timestamp (format is ISO 8601 standard in UTC).
|
|
70
|
+
*/
|
|
71
|
+
published_at: string | null;
|
|
72
|
+
id: number;
|
|
73
|
+
uuid: string;
|
|
74
|
+
/**
|
|
75
|
+
* Dynamic component data rendered by Storyblok, structure varies by component.
|
|
76
|
+
*/
|
|
77
|
+
content: {
|
|
78
|
+
_uid?: string;
|
|
79
|
+
component?: string;
|
|
80
|
+
[key: string]: unknown | string | undefined;
|
|
81
|
+
};
|
|
82
|
+
slug: string;
|
|
83
|
+
full_slug: string;
|
|
84
|
+
sort_by_date: string | null;
|
|
85
|
+
position: number;
|
|
86
|
+
tag_list: Array<string>;
|
|
87
|
+
is_startpage: boolean;
|
|
88
|
+
parent_id: number;
|
|
89
|
+
/**
|
|
90
|
+
* Custom metadata for the story.
|
|
91
|
+
*/
|
|
92
|
+
meta_data: {
|
|
93
|
+
[key: string]: unknown;
|
|
94
|
+
} | null;
|
|
95
|
+
group_id: string;
|
|
96
|
+
first_published_at: string | null;
|
|
97
|
+
release_id?: number | null;
|
|
98
|
+
lang: string;
|
|
99
|
+
path: string | null;
|
|
100
|
+
alternates: Array<StoryAlternate>;
|
|
101
|
+
default_full_slug: string | null;
|
|
102
|
+
translated_slugs: Array<{
|
|
103
|
+
path: string;
|
|
104
|
+
name: string | null;
|
|
105
|
+
lang: string;
|
|
106
|
+
published: string | null;
|
|
107
|
+
}> | null;
|
|
108
|
+
};
|
|
109
|
+
type StoryAlternate = {
|
|
110
|
+
id: number;
|
|
111
|
+
name: string;
|
|
112
|
+
slug: string;
|
|
113
|
+
published: boolean | null;
|
|
114
|
+
full_slug: string;
|
|
115
|
+
is_folder: boolean;
|
|
116
|
+
parent_id: number;
|
|
117
|
+
};
|
|
118
|
+
//#endregion
|
|
119
|
+
export { CapiStory };
|
|
120
|
+
//# sourceMappingURL=_internal.gen.d.mts.map
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
//#region src/generated/capi/types.gen.d.ts
|
|
2
|
+
type StoryAlternate = {
|
|
3
|
+
id: number;
|
|
4
|
+
name: string;
|
|
5
|
+
slug: string;
|
|
6
|
+
published: boolean | null;
|
|
7
|
+
full_slug: string;
|
|
8
|
+
is_folder: boolean;
|
|
9
|
+
parent_id: number;
|
|
10
|
+
};
|
|
11
|
+
type Datasource = {
|
|
12
|
+
/**
|
|
13
|
+
* ID.
|
|
14
|
+
*/
|
|
15
|
+
id: number;
|
|
16
|
+
/**
|
|
17
|
+
* Name.
|
|
18
|
+
*/
|
|
19
|
+
name: string;
|
|
20
|
+
/**
|
|
21
|
+
* The unique slug of the datasource.
|
|
22
|
+
*/
|
|
23
|
+
slug: string;
|
|
24
|
+
/**
|
|
25
|
+
* Dimensions of the datasource.
|
|
26
|
+
*/
|
|
27
|
+
dimensions: Array<Dimension>;
|
|
28
|
+
/**
|
|
29
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
30
|
+
*/
|
|
31
|
+
created_at?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
34
|
+
*/
|
|
35
|
+
updated_at?: string;
|
|
36
|
+
};
|
|
37
|
+
type DatasourceEntry = {
|
|
38
|
+
/**
|
|
39
|
+
* ID.
|
|
40
|
+
*/
|
|
41
|
+
id: number;
|
|
42
|
+
/**
|
|
43
|
+
* Name.
|
|
44
|
+
*/
|
|
45
|
+
name: string;
|
|
46
|
+
/**
|
|
47
|
+
* Given value in default dimension.
|
|
48
|
+
*/
|
|
49
|
+
value: string;
|
|
50
|
+
/**
|
|
51
|
+
* Given value in the requested dimension.
|
|
52
|
+
*/
|
|
53
|
+
dimension_value: string | null;
|
|
54
|
+
};
|
|
55
|
+
type Link = {
|
|
56
|
+
/**
|
|
57
|
+
* ID.
|
|
58
|
+
*/
|
|
59
|
+
id: number;
|
|
60
|
+
uuid: string;
|
|
61
|
+
/**
|
|
62
|
+
* The full slug of the story or folder.
|
|
63
|
+
*/
|
|
64
|
+
slug: string;
|
|
65
|
+
/**
|
|
66
|
+
* Real path defined in the story's entry configuration.
|
|
67
|
+
*/
|
|
68
|
+
path?: string | null;
|
|
69
|
+
/**
|
|
70
|
+
* Either the full slug of the story or folder with a leading /, or, if existent, the value of the real path defined in the story's entry configuration with a leading /.
|
|
71
|
+
*/
|
|
72
|
+
real_path?: string | null;
|
|
73
|
+
/**
|
|
74
|
+
* The complete name of the story or folder.
|
|
75
|
+
*/
|
|
76
|
+
name: string;
|
|
77
|
+
/**
|
|
78
|
+
* true if a story is currently published, even if it has unpublished changes.
|
|
79
|
+
*/
|
|
80
|
+
published: boolean;
|
|
81
|
+
/**
|
|
82
|
+
* ID of the parent folder.
|
|
83
|
+
*/
|
|
84
|
+
parent_id: number;
|
|
85
|
+
/**
|
|
86
|
+
* true if the instance constitutes a folder.
|
|
87
|
+
*/
|
|
88
|
+
is_folder: boolean;
|
|
89
|
+
/**
|
|
90
|
+
* true if the story is defined as root for the folder.
|
|
91
|
+
*/
|
|
92
|
+
is_startpage: boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Numeric representation of the story's position in the folder.
|
|
95
|
+
*/
|
|
96
|
+
position: number;
|
|
97
|
+
/**
|
|
98
|
+
* Latest publication timestamp (format is ISO 8601 standard in UTC).
|
|
99
|
+
*/
|
|
100
|
+
published_at?: string | null;
|
|
101
|
+
/**
|
|
102
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
103
|
+
*/
|
|
104
|
+
created_at?: string | null;
|
|
105
|
+
/**
|
|
106
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
107
|
+
*/
|
|
108
|
+
updated_at?: string | null;
|
|
109
|
+
/**
|
|
110
|
+
* Alternate language variants.
|
|
111
|
+
*/
|
|
112
|
+
alternates?: Array<Alternate>;
|
|
113
|
+
};
|
|
114
|
+
type Tag = {
|
|
115
|
+
/**
|
|
116
|
+
* The name of the tag.
|
|
117
|
+
*/
|
|
118
|
+
name: string;
|
|
119
|
+
/**
|
|
120
|
+
* The minimum value of `taggings_count` is 1, not 0.
|
|
121
|
+
* - The number of tags with this name that exist in the space, or
|
|
122
|
+
* - The number of draft or published stories with this tag, or
|
|
123
|
+
* - The number of deleted stories with this tag.
|
|
124
|
+
*/
|
|
125
|
+
taggings_count?: number;
|
|
126
|
+
/**
|
|
127
|
+
* Only visible when passing the `all_tags` parameter. The number of stories currently associated with the tag, corresponding to the <strong>Assigned items</strong> column in the <a href='https://www.storyblok.com/docs/manuals/stories#tags'>Tags tab</a>.
|
|
128
|
+
*/
|
|
129
|
+
tag_on_stories?: number;
|
|
130
|
+
};
|
|
131
|
+
type Dimension = {
|
|
132
|
+
/**
|
|
133
|
+
* ID.
|
|
134
|
+
*/
|
|
135
|
+
id: number;
|
|
136
|
+
/**
|
|
137
|
+
* Name.
|
|
138
|
+
*/
|
|
139
|
+
name: string;
|
|
140
|
+
/**
|
|
141
|
+
* The value provided for the datasource dimension.
|
|
142
|
+
*/
|
|
143
|
+
entry_value: string;
|
|
144
|
+
/**
|
|
145
|
+
* The numeric ID of the datasource that the dimension belongs to.
|
|
146
|
+
*/
|
|
147
|
+
datasource_id?: number;
|
|
148
|
+
/**
|
|
149
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
150
|
+
*/
|
|
151
|
+
created_at?: string;
|
|
152
|
+
/**
|
|
153
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
154
|
+
*/
|
|
155
|
+
updated_at?: string;
|
|
156
|
+
};
|
|
157
|
+
type Alternate = {
|
|
158
|
+
/**
|
|
159
|
+
* Translated slug (or parent slug if not installed).
|
|
160
|
+
*/
|
|
161
|
+
path: string;
|
|
162
|
+
/**
|
|
163
|
+
* Translated name of the story or folder.
|
|
164
|
+
*/
|
|
165
|
+
name: string;
|
|
166
|
+
/**
|
|
167
|
+
* Language code of this story variant.
|
|
168
|
+
*/
|
|
169
|
+
lang: string;
|
|
170
|
+
/**
|
|
171
|
+
* True if this variant is published.
|
|
172
|
+
*/
|
|
173
|
+
published: boolean;
|
|
174
|
+
/**
|
|
175
|
+
* Translated slug of the story.
|
|
176
|
+
*/
|
|
177
|
+
translated_slug: string;
|
|
178
|
+
};
|
|
179
|
+
//#endregion
|
|
180
|
+
export { Datasource, DatasourceEntry, Link, StoryAlternate, Tag };
|
|
181
|
+
//# sourceMappingURL=types.gen.d.cts.map
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
//#region src/generated/capi/types.gen.d.ts
|
|
2
|
+
type StoryAlternate = {
|
|
3
|
+
id: number;
|
|
4
|
+
name: string;
|
|
5
|
+
slug: string;
|
|
6
|
+
published: boolean | null;
|
|
7
|
+
full_slug: string;
|
|
8
|
+
is_folder: boolean;
|
|
9
|
+
parent_id: number;
|
|
10
|
+
};
|
|
11
|
+
type Datasource = {
|
|
12
|
+
/**
|
|
13
|
+
* ID.
|
|
14
|
+
*/
|
|
15
|
+
id: number;
|
|
16
|
+
/**
|
|
17
|
+
* Name.
|
|
18
|
+
*/
|
|
19
|
+
name: string;
|
|
20
|
+
/**
|
|
21
|
+
* The unique slug of the datasource.
|
|
22
|
+
*/
|
|
23
|
+
slug: string;
|
|
24
|
+
/**
|
|
25
|
+
* Dimensions of the datasource.
|
|
26
|
+
*/
|
|
27
|
+
dimensions: Array<Dimension>;
|
|
28
|
+
/**
|
|
29
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
30
|
+
*/
|
|
31
|
+
created_at?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
34
|
+
*/
|
|
35
|
+
updated_at?: string;
|
|
36
|
+
};
|
|
37
|
+
type DatasourceEntry = {
|
|
38
|
+
/**
|
|
39
|
+
* ID.
|
|
40
|
+
*/
|
|
41
|
+
id: number;
|
|
42
|
+
/**
|
|
43
|
+
* Name.
|
|
44
|
+
*/
|
|
45
|
+
name: string;
|
|
46
|
+
/**
|
|
47
|
+
* Given value in default dimension.
|
|
48
|
+
*/
|
|
49
|
+
value: string;
|
|
50
|
+
/**
|
|
51
|
+
* Given value in the requested dimension.
|
|
52
|
+
*/
|
|
53
|
+
dimension_value: string | null;
|
|
54
|
+
};
|
|
55
|
+
type Link = {
|
|
56
|
+
/**
|
|
57
|
+
* ID.
|
|
58
|
+
*/
|
|
59
|
+
id: number;
|
|
60
|
+
uuid: string;
|
|
61
|
+
/**
|
|
62
|
+
* The full slug of the story or folder.
|
|
63
|
+
*/
|
|
64
|
+
slug: string;
|
|
65
|
+
/**
|
|
66
|
+
* Real path defined in the story's entry configuration.
|
|
67
|
+
*/
|
|
68
|
+
path?: string | null;
|
|
69
|
+
/**
|
|
70
|
+
* Either the full slug of the story or folder with a leading /, or, if existent, the value of the real path defined in the story's entry configuration with a leading /.
|
|
71
|
+
*/
|
|
72
|
+
real_path?: string | null;
|
|
73
|
+
/**
|
|
74
|
+
* The complete name of the story or folder.
|
|
75
|
+
*/
|
|
76
|
+
name: string;
|
|
77
|
+
/**
|
|
78
|
+
* true if a story is currently published, even if it has unpublished changes.
|
|
79
|
+
*/
|
|
80
|
+
published: boolean;
|
|
81
|
+
/**
|
|
82
|
+
* ID of the parent folder.
|
|
83
|
+
*/
|
|
84
|
+
parent_id: number;
|
|
85
|
+
/**
|
|
86
|
+
* true if the instance constitutes a folder.
|
|
87
|
+
*/
|
|
88
|
+
is_folder: boolean;
|
|
89
|
+
/**
|
|
90
|
+
* true if the story is defined as root for the folder.
|
|
91
|
+
*/
|
|
92
|
+
is_startpage: boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Numeric representation of the story's position in the folder.
|
|
95
|
+
*/
|
|
96
|
+
position: number;
|
|
97
|
+
/**
|
|
98
|
+
* Latest publication timestamp (format is ISO 8601 standard in UTC).
|
|
99
|
+
*/
|
|
100
|
+
published_at?: string | null;
|
|
101
|
+
/**
|
|
102
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
103
|
+
*/
|
|
104
|
+
created_at?: string | null;
|
|
105
|
+
/**
|
|
106
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
107
|
+
*/
|
|
108
|
+
updated_at?: string | null;
|
|
109
|
+
/**
|
|
110
|
+
* Alternate language variants.
|
|
111
|
+
*/
|
|
112
|
+
alternates?: Array<Alternate>;
|
|
113
|
+
};
|
|
114
|
+
type Tag = {
|
|
115
|
+
/**
|
|
116
|
+
* The name of the tag.
|
|
117
|
+
*/
|
|
118
|
+
name: string;
|
|
119
|
+
/**
|
|
120
|
+
* The minimum value of `taggings_count` is 1, not 0.
|
|
121
|
+
* - The number of tags with this name that exist in the space, or
|
|
122
|
+
* - The number of draft or published stories with this tag, or
|
|
123
|
+
* - The number of deleted stories with this tag.
|
|
124
|
+
*/
|
|
125
|
+
taggings_count?: number;
|
|
126
|
+
/**
|
|
127
|
+
* Only visible when passing the `all_tags` parameter. The number of stories currently associated with the tag, corresponding to the <strong>Assigned items</strong> column in the <a href='https://www.storyblok.com/docs/manuals/stories#tags'>Tags tab</a>.
|
|
128
|
+
*/
|
|
129
|
+
tag_on_stories?: number;
|
|
130
|
+
};
|
|
131
|
+
type Dimension = {
|
|
132
|
+
/**
|
|
133
|
+
* ID.
|
|
134
|
+
*/
|
|
135
|
+
id: number;
|
|
136
|
+
/**
|
|
137
|
+
* Name.
|
|
138
|
+
*/
|
|
139
|
+
name: string;
|
|
140
|
+
/**
|
|
141
|
+
* The value provided for the datasource dimension.
|
|
142
|
+
*/
|
|
143
|
+
entry_value: string;
|
|
144
|
+
/**
|
|
145
|
+
* The numeric ID of the datasource that the dimension belongs to.
|
|
146
|
+
*/
|
|
147
|
+
datasource_id?: number;
|
|
148
|
+
/**
|
|
149
|
+
* Creation timestamp (format is ISO 8601 standard in UTC).
|
|
150
|
+
*/
|
|
151
|
+
created_at?: string;
|
|
152
|
+
/**
|
|
153
|
+
* Latest update timestamp (format is ISO 8601 standard in UTC).
|
|
154
|
+
*/
|
|
155
|
+
updated_at?: string;
|
|
156
|
+
};
|
|
157
|
+
type Alternate = {
|
|
158
|
+
/**
|
|
159
|
+
* Translated slug (or parent slug if not installed).
|
|
160
|
+
*/
|
|
161
|
+
path: string;
|
|
162
|
+
/**
|
|
163
|
+
* Translated name of the story or folder.
|
|
164
|
+
*/
|
|
165
|
+
name: string;
|
|
166
|
+
/**
|
|
167
|
+
* Language code of this story variant.
|
|
168
|
+
*/
|
|
169
|
+
lang: string;
|
|
170
|
+
/**
|
|
171
|
+
* True if this variant is published.
|
|
172
|
+
*/
|
|
173
|
+
published: boolean;
|
|
174
|
+
/**
|
|
175
|
+
* Translated slug of the story.
|
|
176
|
+
*/
|
|
177
|
+
translated_slug: string;
|
|
178
|
+
};
|
|
179
|
+
//#endregion
|
|
180
|
+
export { Datasource, DatasourceEntry, Link, StoryAlternate, Tag };
|
|
181
|
+
//# sourceMappingURL=types.gen.d.mts.map
|