Atom Namespace Reference
The Atom namespace allows RSS and RDF feeds to include Atom-specific elements, providing richer metadata and linking capabilities. This namespace provides partial Atom elements that can be embedded within other feed formats.
| Namespace URI | http://www.w3.org/2005/Atom |
|---|---|
| Specification | RFC 4287 - Atom Syndication Format |
| Prefix | <atom:*> |
| Available in | RSS, RDF |
| Property | atom |
Types
INFO
For details on type parameters (TDate, TStrict) and Requirable<T> markers, see TypeScript Reference.
ts
export namespace Atom {
// For simplicity's sake, a string is used for now, but this may be reconsidered in the future.
export type Text = string
export type Link<TDate extends DateLike, TStrict extends boolean = false> = Strict<
{
href: Requirable<string> // Required in spec.
rel?: string
type?: string
hreflang?: string
title?: string
length?: number
thr?: ThrNs.Link<TDate>
},
TStrict
>
export type Person<TStrict extends boolean = false> = Strict<
{
name: Requirable<string> // Required in spec.
uri?: string
email?: string
arxiv?: ArxivNs.Author
},
TStrict
>
export type Category<TStrict extends boolean = false> = Strict<
{
term: Requirable<string> // Required in spec.
scheme?: string
label?: string
},
TStrict
>
export type Generator<TStrict extends boolean = false> = Strict<
{
text: Requirable<string> // Required in spec.
uri?: string
version?: string
},
TStrict
>
export type Source<TDate extends DateLike, TStrict extends boolean = false> = {
authors?: Array<Person<TStrict>>
categories?: Array<Category<TStrict>>
contributors?: Array<Person<TStrict>>
generator?: Generator<TStrict>
icon?: string
id?: string
links?: Array<Link<TDate, TStrict>>
logo?: string
rights?: Text
subtitle?: Text
title?: Text
updated?: TDate
}
export type Entry<TDate extends DateLike, TStrict extends boolean = false> = Strict<
{
authors?: Array<Person<TStrict>>
categories?: Array<Category<TStrict>>
content?: Text
contributors?: Array<Person<TStrict>>
id: Requirable<string> // Required in spec.
links?: Array<Link<TDate, TStrict>>
published?: TDate
rights?: Text
source?: Source<TDate, TStrict>
summary?: Text
title: Requirable<Text> // Required in spec.
updated: Requirable<TDate> // Required in spec.
app?: AppNs.Entry<TDate>
arxiv?: ArxivNs.Entry
cc?: CcNs.ItemOrFeed
dc?: DcNs.ItemOrFeed<TDate>
slash?: SlashNs.Item
itunes?: ItunesNs.Item
googleplay?: GooglePlayNs.Item<TStrict>
psc?: PscNs.Item<TStrict>
media?: MediaNs.ItemOrFeed<TStrict>
georss?: GeoRssNs.ItemOrFeed<TStrict>
geo?: GeoNs.ItemOrFeed
thr?: ThrNs.Item<TStrict>
dcterms?: DcTermsNs.ItemOrFeed<TDate>
creativeCommons?: CreativeCommonsNs.ItemOrFeed
wfw?: WfwNs.Item
yt?: YtNs.Item
pingback?: PingbackNs.Item
trackback?: TrackbackNs.Item
xml?: XmlNs.ItemOrFeed
},
TStrict
>
export type Feed<TDate extends DateLike, TStrict extends boolean = false> = Strict<
{
authors?: Array<Person<TStrict>>
categories?: Array<Category<TStrict>>
contributors?: Array<Person<TStrict>>
generator?: Generator<TStrict>
icon?: string
id: Requirable<string> // Required in spec.
links?: Array<Link<TDate, TStrict>>
logo?: string
rights?: Text
subtitle?: Text
title: Requirable<Text> // Required in spec.
updated: Requirable<TDate> // Required in spec.
entries?: Array<Entry<TDate, TStrict>>
cc?: CcNs.ItemOrFeed
dc?: DcNs.ItemOrFeed<TDate>
sy?: SyNs.Feed<TDate>
itunes?: ItunesNs.Feed<TStrict>
googleplay?: GooglePlayNs.Feed<TStrict>
media?: MediaNs.ItemOrFeed<TStrict>
georss?: GeoRssNs.ItemOrFeed<TStrict>
geo?: GeoNs.ItemOrFeed
dcterms?: DcTermsNs.ItemOrFeed<TDate>
creativeCommons?: CreativeCommonsNs.ItemOrFeed
opensearch?: OpenSearchNs.Feed<TStrict>
yt?: YtNs.Feed
admin?: AdminNs.Feed
pingback?: PingbackNs.Feed
xml?: XmlNs.ItemOrFeed
},
TStrict
>
}Related
- Atom Feed Fields - Complete Atom feed specification
- Parsing Namespaces - How namespace parsing works