Differences between revisions 2 and 3
Revision 2 as of 2023-127 03:34:14
Size: 1949
Editor: Singpolyma
Comment: add builds.sr.ht webhook mapping
Revision 3 as of 2023-127 03:34:27
Size: 1949
Editor: Singpolyma
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
# ntfy.sh = ntfy.sh
Line 69: Line 69:
# builds.sr.ht = builds.sr.ht

ntfy.sh

Convert ntfy.sh publish JSON format into Atom entry

{
	"type": "object",
	"xml": {
		"name": "entry",
		"namespace": "http://www.w3.org/2005/Atom"
	},
	"properties": {
		"title": { "type": "string" },
		"message": {
			"type": "string",
			"xml": { "name": "content" }
		},
		"tags": {
			"type": "array",
			"items": {
				"type": "string",
				"xml": {
					"name": "category",
					"x_single_attribute": "term"
				}
			}
		},
		"attach": {
			"type": "string",
			"xml": {
				"name": "link",
				"x_single_attribute": "href"
			}
		},
		"click": {
			"type": "string",
			"xml": {
				"name": "link",
				"x_single_attribute": "href"
			}
		},
		"actions": {
			"type": "array",
			"items": {
				"type": "object",
				"xml": { "name": "link" },
				"properties": {
					"label": {
						"type": "string",
						"xml": {
							"name": "title",
							"attribute": true
						}
					},
					"url": {
						"type": "string",
						"xml": {
							"name": "href",
							"attribute": true
						}
					}
				}
			}
		}
	}
}

builds.sr.ht

Not quite working yet due to https://lists.sr.ht/~sircmpwn/sr.ht-discuss/%3CZFcbdOBEGfhA1gI1%40singpolyma-beefy.lan%3E

{
	"type": "object",
	"xml": {
		"name": "entry",
		"namespace": "http://www.w3.org/2005/Atom"
	},
	"properties": {
		"id": { "type": "integer" },
		"tags": {
			"type": "string",
			"xml": { "name": "title" }
		},
		"owner": {
			"type": "object",
			"xml": { "name": "author" },
			"properties": {
				"name": { "type": "string" }
			}
		},
		"note": {
			"type": "string",
			"xml": { "name": "content" }
		},
		"setup_log": {
			"type": "string",
			"xml": {
				"name": "link",
				"x_single_attribute": "href"
			}
		},
		"status": {
			"type": "string",
			"xml": {
				"name": "category",
				"x_single_attribute": "term"
			}
		}
	}
}

DatamapperSchemas (last edited 2023-127 03:34:27 by Singpolyma)