@sockethub/platform-feeds 4.0.0-alpha.10 → 4.0.0-alpha.12
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/README.md +27 -10
- package/dist/index.js +16395 -23
- package/dist/index.js.map +154 -5
- package/package.json +7 -7
- package/src/index.test.ts +8 -4
- package/src/index.ts +19 -13
- package/src/schema.ts +15 -0
- package/src/types.ts +2 -3
package/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This platform fetches RSS and Atom feeds from URLs and converts feed entries int
|
|
|
8
8
|
ActivityStreams objects. It handles various feed formats and provides structured data for
|
|
9
9
|
web applications to consume feed content.
|
|
10
10
|
|
|
11
|
-
## Implemented Verbs (
|
|
11
|
+
## Implemented Verbs (`type`)
|
|
12
12
|
|
|
13
13
|
* **fetch** - Retrieve and parse an RSS or Atom feed
|
|
14
14
|
|
|
@@ -18,10 +18,15 @@ web applications to consume feed content.
|
|
|
18
18
|
|
|
19
19
|
```json
|
|
20
20
|
{
|
|
21
|
-
"
|
|
22
|
-
"context":
|
|
21
|
+
"type": "fetch",
|
|
22
|
+
"@context": [
|
|
23
|
+
"https://www.w3.org/ns/activitystreams",
|
|
24
|
+
"https://sockethub.org/ns/context/v1.jsonld",
|
|
25
|
+
"https://sockethub.org/ns/context/platform/feeds/v1.jsonld"
|
|
26
|
+
],
|
|
23
27
|
"actor": {
|
|
24
|
-
"
|
|
28
|
+
"id": "https://example.com/feed.xml",
|
|
29
|
+
"type": "feed"
|
|
25
30
|
}
|
|
26
31
|
}
|
|
27
32
|
```
|
|
@@ -32,19 +37,31 @@ Returns an ActivityStreams Collection with feed entries:
|
|
|
32
37
|
|
|
33
38
|
```json
|
|
34
39
|
{
|
|
35
|
-
"
|
|
36
|
-
"context":
|
|
40
|
+
"type": "collection",
|
|
41
|
+
"@context": [
|
|
42
|
+
"https://www.w3.org/ns/activitystreams",
|
|
43
|
+
"https://sockethub.org/ns/context/v1.jsonld",
|
|
44
|
+
"https://sockethub.org/ns/context/platform/feeds/v1.jsonld"
|
|
45
|
+
],
|
|
46
|
+
"summary": "Example Blog",
|
|
37
47
|
"totalItems": 10,
|
|
38
48
|
"items": [
|
|
39
49
|
{
|
|
40
|
-
"
|
|
50
|
+
"type": "post",
|
|
51
|
+
"@context": [
|
|
52
|
+
"https://www.w3.org/ns/activitystreams",
|
|
53
|
+
"https://sockethub.org/ns/context/v1.jsonld",
|
|
54
|
+
"https://sockethub.org/ns/context/platform/feeds/v1.jsonld"
|
|
55
|
+
],
|
|
41
56
|
"actor": {
|
|
42
|
-
"
|
|
57
|
+
"id": "https://example.com/feed.xml",
|
|
58
|
+
"type": "feed",
|
|
43
59
|
"name": "Example Blog"
|
|
44
60
|
},
|
|
45
61
|
"object": {
|
|
46
|
-
"
|
|
47
|
-
"
|
|
62
|
+
"id": "https://example.com/post/1",
|
|
63
|
+
"type": "article",
|
|
64
|
+
"title": "Blog Post Title",
|
|
48
65
|
"content": "Post content...",
|
|
49
66
|
"url": "https://example.com/post/1",
|
|
50
67
|
"published": "2023-01-01T12:00:00Z"
|