Releases: fedify-dev/fedify
Fedify 0.9.1
Released on June 13, 2024.
- Fixed a bug of Activity Vocabulary API that
clone()method of Vocabulary classes had not cloned theidproperty from the source object.
Fedify 0.9.0
Released on June 2, 2024.
-
Added
Tombstoneclass to Activity Vocabulary API. -
Added
Hashtagclass to Activity Vocabulary API. [#48] -
Added
Emojiclass to Activity Vocabulary API. [#48] -
Added an actor handle normalization function.
- Added
normalizeActorHandle()function. - Added
NormalizeActorHandleOptionsinterface. - The
getActorHandle()function now guarantees that the returned actor handle is normalized. - Added the second optional parameter to
getActorHandle()function. - The return type of
getActorHandle()function becamePromise<`@${string}@${string}` | `${string}@${string}`>(wasPromise<`@${string}@${string}`>).
- Added
-
Added
excludeBaseUrisoption toContext.sendActivity()andFederation.sendActivity()methods.- Added
SendActivityOptions.excludeBaseUrisproperty. - Added
ExtractInboxesParameters.excludeBaseUrisproperty.
- Added
-
The
Contextnow can parse URIs of objects, inboxes, and collections as well as actors.- Added
Context.parseUri()method. - Added
ParseUriResulttype. - Deprecated
Context.getHandleFromActorUri()method.
- Added
-
The time window for signature verification is now configurable. [#52]
- The default time window for signature verification is now a minute (was 30 seconds).
- Added
signatureTimeWindowoption toFederationParametersinterface. - Added
VerifyOptionsinterface. - The signature of the
verify()function is revamped; it now optionally takes aVerifyOptionsobject as the second parameter.
-
Renamed the
@fedify/fedify/httpsigmodule to@fedify/fedify/sig, and also:- Deprecated
sign()function. UsesignRequest()instead. - Deprecated
verify()function. UseverifyRequest()instead. - Deprecated
VerifyOptionsinterface. UseVerifyRequestOptionsinstead.
- Deprecated
-
When signing an HTTP request, the
algorithmparameter is now added to theSignatureheader. This change improves the compatibility with Misskey and other implementations that require thealgorithmparameter. -
Added more log messages using the LogTape library. Currently the below logger categories are used:
["fedify", "federation", "actor"]["fedify", "federation", "http"]["fedify", "sig", "http"]["fedify", "sig", "key"]["fedify", "sig", "owner"]
Fedify 0.8.0
Released on May 6, 2024.
-
The CLI toolchain for testing and debugging is now available on JSR: @fedify/cli. You can install it with
deno install -A --unstable-fs --unstable-kv --unstable-temporal -n fedify jsr:@fedify/cli, or download a standalone executable from the releases page.- Added
fedifycommand. - Added
fedify lookupsubcommand. - Added
fedify inboxsubcommand.
- Added
-
Implemented followers collection synchronization mechanism.
- Added
RequestContext.sendActivity()overload that takes"followers"as the second parameter. - Added the second type parameter to
CollectionCallbackSettersinterface. - Added the second type parameter to
CollectionDispatchertype. - Added the fourth parameter to
CollectionDispatchertype. - Added the second type parameter to
CollectionCountertype. - Added the third parameter to
CollectionCountertype. - Added the second type parameter to
CollectionCursortype. - Added the third parameter to
CollectionCursortype.
- Added
-
Relaxed the required type for activity recipients.
- Added
Recipientinterface. - The type of the second parameter of
Context.sendActivity()method becameRecipient | Recipient[](wasActor | Actor[]). However, sinceRecipientis a supertype ofActor, the existing code should work without any change.
- Added
-
Followers collection now has to consist of
Recipientobjects only. (It could consist ofURLs as well asActors before.)- The type of
Federation.setFollowersDispatcher()method's second parameter becameCollectionDispatcher<Recipient, TContextData, URL>(wasCollectionDispatcher<Actor | URL, TContextData>).
- The type of
-
Some of the responsibility of a document loader was separated to a context loader and a document loader.
- Added
contextLoaderoption to constructors,fromJsonLd()static methods,clone()methods, and all non-scalar accessors (get*()) of Activity Vocabulary classes. - Renamed
documentLoaderoption tocontextLoaderintoJsonLd()methods of Activity Vocabulary objects. - Added
contextLoaderoption toLookupObjectOptionsinterface. - Added
contextLoaderproperty toContextinterface. - Added
contextLoaderoption toFederationParametersinterface. - Renamed
documentLoaderoption tocontextLoaderinRespondWithObjectOptionsinterface. - Added
GetKeyOwnerOptionsinterface. - The type of the second parameter of
getKeyOwner()function becameGetKeyOwnerOptions(wasDocumentLoader). - Added
DoesActorOwnKeyOptionsinterface. - The type of the third parameter of
doesActorOwnKey()function becameDoesActorOwnKeyOptions(wasDocumentLoader).
- Added
-
Added
widthandheightproperties toDocumentclass for better compatibility with Mastodon. [#47]- Added
Document.widthproperty. - Added
Document.heightproperty. new Document()constructor now acceptswidthoption.new Document()constructor now acceptsheightoption.Document.clone()method now acceptswidthoption.Document.clone()method now acceptsheightoption.
- Added
-
Removed the dependency on @js-temporal/polyfill on Deno, and Fedify now requires
--unstable-temporalflag. On other runtime, it still depends on @js-temporal/polyfill. -
Added more log messages using the LogTape library. Currently the below logger categories are used:
["fedify", "federation", "collection"]["fedify", "httpsig", "verify"]["fedify", "runtime", "docloader"]
-
Fixed a bug where the authenticated document loader had thrown
InvalidUrlerror when the URL redirection was involved in Bun. -
Fixed a bug of
lookupObject()that it had failed to look up the actor object when WebFinger response had no links with"type": "application/activity+json"but had"type": "application/ld+json; profile=\"https://www.w3.org/ns/activitystreams\"".
Fedify 0.7.0
Released on April 23, 2024.
-
Added
PUBLIC_COLLECTIONconstant for public addressing. -
Federationnow supports authorized fetch for actor dispatcher and collection dispatchers.- Added
ActorCallbackSetters.authorize()method. - Added
CollectionCallbackSetters.authorize()method. - Added
AuthorizedPredicatetype. - Added
RequestContext.getSignedKey()method. - Added
RequestContext.getSignedKeyOwner()method. - Added
FederationFetchOptions.onUnauthorizedoption for handling unauthorized fetches. - Added
getKeyOwner()function.
- Added
-
The default implementation of
FederationFetchOptions.onNotAcceptableoption now responds withVary: Accept, Signatureheader. -
Added log messages using the LogTape library. Currently the below logger categories are used:
["fedify"]["fedify", "federation"]["fedify", "federation", "inbox"]["fedify", "federation", "outbox"]
-
Added
RequestContext.getActor()method. -
Activity Vocabulary classes now have
typeIdstatic property. -
Dispatcher setters and inbox listener setters in
Federationnow take a path as`${string}{handle}${string}`instead ofstringso that it is more type-safe. -
Added generalized object dispatchers. [#33]
- Added
Federation.setObjectDispatcher()method. - Added
ObjectDispatchertype. - Added
ObjectAuthorizePredicatetype. - Added
Context.getObjectUri()method. - Added
RequestContext.getObject()method.
- Added
Fedify 0.6.1
Released on April 17, 2024.
- Fixed a bug of
new Federation()constructor that if it is once called the process will never exit. [#39]
Fedify 0.5.2
Released on April 17, 2024.
- Fixed a bug of
new Federation()constructor that if it is once called the process will never exit. [#39]
Fedify 0.6.0
Released on April 9, 2024.
-
DocumentLoaderis now propagated to the loaded remote objects from Activity Vocabulary objects. [#27]- Added
optionsparameter to Activity Vocabulary constructors. - Added
optionsparameter toclone()method of Activity Vocabulary objects. - The Activity Vocabulary object passed to
InboxListenernow implicitly loads remote object with an authenticatedDocumentLoader.
- Added
-
Added
Federation.fetch()method.- Deprecated
Federation.handle()method. UseFederation.fetch()method instead. - Renamed
FederationHandlerParameterstype toFederationFetchOptions. - Added
integrateFetchOptions()function. - Deprecated
integrateHandlerOptions()function.
- Deprecated
-
Added
@fedify/fedify/x/honomodule for integrating with Hono middleware. [#25]- Added
federation()function. - Added
ContextDataFactorytype.
- Added
-
Context.sendActivity()method now throwsTypeErrorinstead of silently failing when the givenActivityobject lacks the actor property. -
Context.sendActivity()method now uses an authenticated document loader under the hood. -
Added outbox error handler to
Federation.- Added
onOutboxErroroption tonew Federation()constructor. - Added
OutboxErrorHandlertype.
- Added
Fedify 0.5.1
Released on April 5, 2024.
- Fixed a bug of
Federationthat its actor/collection dispatchers had done content negotiation before determining if the resource exists or not. It also fixed a bug thatintegrateHandler()from@fedify/fedify/x/freshhad responded with406 Not Acceptableinstead of404 Not Foundwhen the resource does not exist in the web browser. [#34]
Fedify 0.5.0
Released on April 2, 2024.
-
Fedify is now available on npm: @fedify/fedify. [#24]
-
Abstract key-value store for caching.
- Added
KvStoreinterface. - Added
KvStoreSetOptionsinterface. - Added
KvKeytype. - Added
DenoKvStoreclass. KvCacheParameters.kvoption now accepts aKvStoreinstead ofDeno.Kv.KvCacheParameters.prefixoption now accepts aKvKeyinstead ofDeno.KvKey.FederationParameters.kvoption now accepts aKvStoreinstead ofDeno.Kv.FederationKvPrefixes.activityIdempotenceoption now accepts aKvKeyinstead ofDeno.KvKey.FederationKvPrefixes.remoteDocumentoption now accepts aKvKeyinstead ofDeno.KvKey.
- Added
-
Abstract message queue for outgoing activities.
- Added
MessageQueueinterface. - Added
MessageQueueEnqueueOptionsinterface. - Added
InProcessMessageQueueclass. - Added
FederationParameters.queueoption.
- Added
-
Added
@fedify/fedify/x/denokvmodule for adaptingDeno.KvtoKvStoreandMessageQueue. It is only available in Deno runtime.- Added
DenoKvStoreclass. - Added
DenoKvMessageQueueclass.
- Added
-
Added
PropertyValueto Activity Vocabulary API. [#29]- Added
PropertyValueclass. new Object()constructor'sattachmentsoption now acceptsPropertyValueobjects.new Object()constructor'sattachmentoption now accepts aPropertyValueobject.Object.getAttachments()method now yieldsPropertyValueobjects besidesObjectandLinkobjects.Object.getAttachment()method now returns aPropertyValueobject besides anObjectand aLinkobject.Object.clone()method'sattachmentsoption now acceptsPropertyValueobjects.Object.clone()method'sattachmentoption now accepts aPropertyValueobject.
- Added
-
Removed dependency on jose.
- Added
exportSpki()function. - Added
importSpki()function.
- Added
-
Fixed a bug that
Application.manuallyApprovesFollowers,Group.manuallyApprovesFollowers,Organization.manuallyApprovesFollowers,Person.manuallyApprovesFollowers, andService.manuallyApprovesFollowersproperties were not properly displayed in Mastodon.
Fedify 0.4.0
Released on March 26, 2024.
-
Added
@fedify/fedify/x/freshmodule for integrating with Fresh middleware.- Added
integrateHandler()function. - Added
integrateHandlerOptions()function.
- Added
-
Added
getActorHandle()function. -
Fedify now has authenticated document loader. [#12]
- Added
Context.getDocumentLoader()method. - Added
getAuthenticatedDocumentLoader()function. - Added
AuthenticatedDocumentLoaderFactorytype. - Added
authenticatedDocumentLoaderFactoryoption tonew Federation()constructor. Context.documentLoaderproperty now returns an authenticated document loader in personal inbox listeners. (Note that it's not affected in shared inbox listeners.)
- Added
-
Added singular accessors to
Object'siconandimageproperties.new Object()constructor now acceptsiconoption.new Object()constructor now acceptsimageoption.- Added
Object.getIcon()method. - Added
Object.getImage()method. Object.clone()method now acceptsiconoption.Object.clone()method now acceptsimageoption.
-
Object'siconandimageproperties no more acceptLinkobjects.new Object()constructor'siconsoption no more acceptsLinkobjects.new Object()constructor'simagesoption no more acceptsLinkobjects.Object.getIcons()method no more yieldsLinkobjects.Object.getImages()method no more yieldsLinkobjects.Object.clone()method'siconsoption no more acceptsLinkobjects.Object.clone()method'simagesoption no more acceptsLinkobjects.
-
Object'sattributedToproperty was renamed toattribution.new Object()constructor'sattributedTooption was renamed toattribution.new Object()constructor'sattributedTosoption was renamed toattributions.Object.getAttributedTo()method is renamed toObject.getAttribution().Object.getAttributedTos()method is renamed toObject.getAttributions().Object.clone()method'sattributedTooption is renamed toattribution.Object.clone()method'sattributedTosoption is renamed toattributions.
-
Object'sattributionproperty (wasattributedTo) now accepts onlyActorobjects.new Object()constructor'sattributionoption (wasattributedTo) now accepts only anActorobject.new Object()constructor'sattributionsoption (wasattributedTos) now accepts onlyActorobjects.Object.getAttribution()method (wasgetAttributedTo()) now returns only anActorobject.Object.getAttributions()method (wasgetAttributedTos()) now returns onlyActorobjects.Object.clone()method'sattributionoption (attributedTo) now accepts only anActorobject.Object.clone()method'sattributionsoption (attributedTos) now accepts onlyActorobjects.
-
Activity'sobjectproperty no more acceptsLinkobjects.new Activity()constructor'sobjectoption no more accepts aLinkobject.new Activity()constructor'sobjectsoption no more acceptsLinkobjects.Activity.getObject()method no more returns aLinkobject.Activity.getObjects()method no more returnsLinkobjects.Activity.clone()method'sobjectoption no more accepts aLinkobject.Activity.clone()method'sobjectsoption no more acceptsLinkobjects.
-
Activity'sactorproperty now accepts onlyActorobjects.new Activity()constructor'sactoroption now accepts only anActorobject.new Activity()constructor'sactorsoption now accepts onlyActorobjects.Activity.getActor()method now returns only anActorobject.Activity.getActors()method now returns onlyActorobjects.Activity.clone()method'sactoroption now accepts only anActorobject.Activity.clone()method'sactorsoption now accepts onlyActorobjects.
-
Added
sensitiveproperty toObjectclass.new Object()constructor now acceptssensitiveoption.- Added
Object.sensitiveattribute. Object.clone()method now acceptssensitiveoption.
-
Now
lookupWebFinger()follows redirections. -
The
http://webfinger.net/rel/profile-pagelinks in WebFinger responses now omittypeproperty.