Extra nodeinfo 2.1 metadata

main
Bob Mottram 2024-05-16 11:05:14 +01:00
parent a5e6a19e63
commit 035fb45272
2 changed files with 22 additions and 2 deletions

View File

@ -123,7 +123,8 @@ def get_nodeinfo(self, ua_str: str, calling_domain: str,
about_url, terms_of_service_url,
registration,
node_info_version,
show_node_info_accounts)
show_node_info_accounts,
domain)
if info:
msg_str = json.dumps(info)
msg_str = convert_domains(calling_domain, referer_domain,

View File

@ -17,7 +17,8 @@ def meta_data_node_info(base_dir: str,
about_url: str,
terms_of_service_url: str,
registration: bool, version: str,
show_accounts: bool) -> {}:
show_accounts: bool,
domain: str) -> {}:
""" /nodeinfo/2.1 endpoint
Also see https://socialhub.activitypub.rocks/t/
https://github.com/jhass/nodeinfo/blob/main/schemas/2.1/example.json
@ -65,7 +66,25 @@ def meta_data_node_info(base_dir: str,
}
},
'metadata': {
'accountActivationRequired': False,
'features': [
'editing',
'exposable_reactions'
],
'chat_enabled': False,
'federatedTimelineAvailable': False,
'federation': {
'enabled': True
},
'suggestions': {
'enabled': False
},
'invitesEnabled': False,
'private': True,
'privilegedStaff': True,
'nodeName': domain,
'mailerEnabled': False,
'publicTimelineVisibility': {},
'postFormats': ['text/plain', 'text/html', 'text/markdown'],
'FEPs': ['c648', '521a', '8fcf', '4ccd', 'c118', 'fffd',
'1970', '0837', '7628', '2677']