Commit Graph

531 Commits (be59d31de9d22a56896bf62819d68bbea0ac9731)

Author SHA1 Message Date
Your Name 396cf2d861 Fix first follower/following record excluded from API responses
Fixes #6695

When no pagination params are provided, the default min_id was set to 1
and the query used 'id > 1', which excluded the very first follower row
(id=1) on fresh instances.

Changed default min_id from 1 to 0 and switched the direction check from
truthy evaluation to !== null, so the query becomes 'id > 0' which
correctly includes all records.
2 months ago
Shift 19880c2ffb
Convert string references to `::class`
PHP 5.5.9 adds the new static `class` property which provides the fully qualified class name. This is preferred over using strings for class names since the `class` property references are checked by PHP.
2 months ago
Daniel Supernault a2be0cb47d
Update CommentController 2 months ago
Daniel Supernault 40aef7a212
Update GroupsFeedController 2 months ago
dansup ca5f83d2d1
Merge pull request #6655 from TowyTowy/fix/timeline-home-nullable-max-id
Fix home timeline rejecting empty max_id/min_id pagination params
2 months ago
dansup 5aae3f46c7
Merge pull request #6691 from pixelfed/shleeable-patch-26
Improve validation
2 months ago
Shlee 1d72f1b437
Update ApiV1Controller.php 3 months ago
Shlee 9966eb50b8
Update ApiV1Controller.php 3 months ago
TowyTowy 795473be55 Fix home timeline rejecting empty max_id/min_id pagination params
`GET /api/v1/timelines/home?max_id=` (empty value) fails validation
because `min_id`/`max_id` use the `sometimes|integer` rule. The global
`ConvertEmptyStringsToNull` middleware turns `?max_id=` into `null`, and
since the field is present, `sometimes` does not skip it while `null`
fails the `integer` rule — returning HTTP 422.

Every other timeline/listing endpoint in this controller (timelinePublic,
accountStatusesById, etc.) uses `nullable|integer` for these params, so
`timelineHome` was the lone outlier. Mastodon-API clients such as Pixelfed
for iOS send `max_id=` on first page load and could not paginate the home
timeline.

Switch `min_id`/`max_id` to `nullable|integer` to match the rest of the
controller.

Fixes #6610

Co-Authored-By: Claude <noreply@anthropic.com>
3 months ago
Your Name b329ee9edc API: Media uploads leak orphaned files when status creation validation fails 7 months ago
Daniel Supernault 695e851026
Fix oauth 8 months ago
Daniel Supernault 3140404835
Update ApiV1Controller.php 9 months ago
Daniel Supernault 80a2f4f2b0
Add api/v1/accounts/lookup endpoint 9 months ago
Daniel Supernault f76567f67b
Improve reblog check 9 months ago
Severin 066f8ee309
Pulls user settings for reblogs 9 months ago
samir 9c3130a3c7 Added pagination to the followers/followings API endpoints 9 months ago
Daniel Supernault 374344754e
Lint 10 months ago
Daniel Supernault 4bc1e22121
Refactor LikePipeline and improve Undo Announce handling 12 months ago
Daniel Supernault 3686c92122
Update Status storage, add SanitizerService to fix spacing in html stripped content 1 year ago
Daniel Supernault 4747266b04
Update ApiV1Controller, fix cache invalidation order 1 year ago
Daniel Supernault 4e938a8ffa
Fix heic, avif, webp support and add libvips driver 1 year ago
Daniel Supernault ab9c13fe0d
New supported formats, Preserve ICC Color Profiles, libvips support
Update image pipeline to handle avif, heic and webp and preserve ICC color profiles and added libvips support.
1 year ago
Daniel Supernault 5a3a1cf76c
Update remove_from_followers api endpoint 2 years ago
daniel 92482c24cd
Merge pull request #5895 from eufelipemateus/feat-remove-follow
[Improvement] Add button remove follow
2 years ago
Felipe Mateus fed800acfb
Merge branch 'dev-contrib-origin' into feat-remove-follow 2 years ago
Daniel Supernault 5a32bfe304
Update ApiV1Controller, add Custom Filters to home/public and hashtag feeds 2 years ago
Daniel Supernault b86102823b
Update CustomFilter model and CustomFilterController 2 years ago
Daniel Supernault 437d742ac4
Add custom filters
Add custom filters, compatible with Mastodon `/api/v2/filters`

Todo:
- [ ] fix routes
- [ ] finish other context filtering
2 years ago
daniel 0158941fb6
API improvements + test fixes (#5925)
* migrate PHPUnit configuration

* replace @test annotations with #[Test] attributes, and add it where it was missing

* remove test prefix from test method names

* add PHPUnit cache to .gitignore

* Update ApiV1Controller, fix notifications favourited/reblogged/bookmarked state. Fixes #5901

* Update ApiV1Controller, fix relationship fields. Fixes #5900

* Update instance config, return proper matrix limits. Fixes #4780

* Update SearchApiV2Service, fix offset bug. Fixes #5875

* Update ApiV1Controller, add better direct error message. Fixes #4789

* Update changelog

---------

Co-authored-by: Daniel Simon <daniel.simon.dev@proton.me>
2 years ago
Daniel Supernault 658fe6898e
Update ApiV1Controller, add better direct error message. Fixes #4789 2 years ago
Daniel Supernault 4732019087
Update instance config, return proper matrix limits. Fixes #4780 2 years ago
Daniel Supernault 8a86808a06
Update ApiV1Controller, fix notifications favourited/reblogged/bookmarked state. Fixes #5901 2 years ago
daniel e5c577054b
Add Pinned Posts + WebUI profile fixes (#5914)
* translate notifications

* translate  profile

* fix translate privacy

* add missing keys

* pinned posts

* fix key  settings

* fix key

Co-Authored-By: daniel <danielsupernault@gmail.com>

* Update AccountImport, improve webp support

* Update GroupSettings, add missing avatar/header deletion

* Update i18n

* Update compiled assets

* Update 2025_03_19_022553_add_pinned_columns_statuses_table.php

* Fix pinned posts implementation

* Update docker readme, closes #5909

* Update post pinning, and dispatch Notification cache warming to a job, and fix reblogged state on some endpoints

* Refactor following check

* Fix ProfileFeed bookmark, likes and shares. Closes #5879

* Update PublicApiController, use pixelfed entities for /api/pixelfed/v1/accounts/id/statuses with bookmarked state

* Update changelog

* Update compiled assets

* Update i18n

---------

Co-authored-by: Felipe Mateus <eu@felipemateus.com>
2 years ago
Daniel Supernault 0f1819125c
Update post pinning, and dispatch Notification cache warming to a job, and fix reblogged state on some endpoints 2 years ago
Daniel Supernault 2f655d0008
Fix pinned posts implementation 2 years ago
daniel c9a0fe0026
Merge pull request #5884 from eufelipemateus/pinned-posts
[Improvement] Pinned posts
2 years ago
Felipe Mateus 128533b5d8
Update ApiV1Controller.php
Co-Authored-By: Mathieu <385764+Casmo@users.noreply.github.com>
2 years ago
Felipe Mateus 456f96d574
add remove follow 2 years ago
Daniel Supernault aa6f95b1cf
Update ApiV1Controller, improve query 2 years ago
Felipe Mateus cce4c41d97
pinned posts 2 years ago
Daniel Supernault 2cf3011816
Update ApiV1Controller, send UndoFollow when cancelling a follow request on remote accounts 2 years ago
Daniel Supernault 976a1873e1
Update ApiV1Controller, improve follower handling 2 years ago
Daniel Supernault c4af4d9921
Update ApiV1Controller.php 2 years ago
Daniel Supernault 244e86bad7
Update ApiV1Controller, add pagination to conversations endpoint with min/max/since id pagination and link header support 2 years ago
Daniel Supernault cce657d9c8
Update ApiV1Controller, return empty statuses feed for private accounts instead of 403 response 2 years ago
Daniel Supernault 38e17a06e0
Update ApiV1Controller, fix max_id pagination on home and public timeline feeds 2 years ago
Daniel Supernault c36cc07b2c
Update avif support, and fix reply permalinks 2 years ago
Daniel Supernault 4ec9f990ed
Update DirectMessageController, fix performance issue 2 years ago
Daniel Supernault 42173245fc
Update ApiV1Controller.php 2 years ago
Daniel Supernault c8ba73f11b
Update ApiV1Controller.php 2 years ago
Daniel Supernault 67f3951e9a
Update ApiV1Controller, add mobile_registration attribute 2 years ago
Daniel Supernault 8fad89543f
DM 2 years ago
daniel 3dd515006c
Merge branch 'staging' into dev 2 years ago
Daniel Supernault 57ede29175
Fix oauth endpoint 2 years ago
root (Deneir) 370f09495a resolve merge conflicts 2 years ago
Daniel Supernault 85124aa642
Fix rendered caption 2 years ago
Daniel Supernault 1d2f76c8e5
Postgres fixes 2 years ago
Daniel Supernault 8ed8305f5d
Update ApiV1Controller.php 2 years ago
Daniel Supernault 9eeb7b6741
Update Status caption logic, stop storing duplicate html caption in db and defer to cached StatusService rendering 2 years ago
Daniel Supernault 9f7cc52c24
Update ApiV1Controller, fix bookmark bug. Closes #5216 2 years ago
Daniel Supernault 424f0271c3
Update ApiV1Controller, fix null caption on media bug 2 years ago
Daniel Supernault 6c48a12423
Update ApiV1Controller, handle Moved accounts 2 years ago
Daniel Supernault dcd95d687c
Update ApiV1Controller, fix v1/instance stats, force cast to int 2 years ago
Daniel Supernault 73b9a75a64
Add UserStorageService 2 years ago
Daniel Supernault c5fbc68745
Update ApiV1Controller 2 years ago
Daniel Supernault 72f681607a
Update ApiV1Controller, fix /api/v1/favourites pagination 2 years ago
Daniel Supernault f61bbecaa9
Update ApiV1Controller, fix support for notification filter types[] 2 years ago
Daniel Supernault 2b9586fce1
Update ApiV1Controller.php 2 years ago
Daniel Supernault f61159a15a
Update ApiV1Controller, add support for notification filter types[] 2 years ago
Daniel Supernault 6e0d1ef41b
Update cache 2 years ago
Daniel Supernault d339b5c251
Update AccountService 2 years ago
Daniel Supernault 165df0ca52
Update ApiV1Controller, update tag feed 2 years ago
Daniel Supernault 679ef677b7
Update ApiController, add pe support to like/unlike endpoints 2 years ago
Daniel Supernault 28bc7aa439
Update ApiV1Controller, fix self relationship response 2 years ago
Daniel Supernault c5e7e91777
Add disable_embeds setting, and fix cache invalidation in other settings 2 years ago
Daniel Supernault d56a4108ec
Update ApiV1Controller, fix cache invalidation bug in update_credentials 2 years ago
Daniel Supernault 19c62aaafa
Update ApiV1Controller, fix update_credentials boolean handling 2 years ago
Daniel Supernault 3f4e0b94ee
Update ApiV1Controller, add settings to verify_credentials endpoint 2 years ago
Daniel Supernault 4aad1c225a
Add api/v1/instance/peers API endpoint, disabled by default 2 years ago
Daniel Supernault d645d6ca26
Update ApiV1Controller, add pe (pixelfed entity) support to /api/v1/statuses/{id}/context endpoint 2 years ago
Daniel Supernault b8e96a5ff3
Update ApiV1Controller, improve refresh relations logic when (un)muting or (un)blocking 3 years ago
Daniel Supernault 6ce513f8c3
Update user_filters, use config_cache 3 years ago
Daniel Supernault 911446c03e
Update app.name config, use config_cache 3 years ago
Daniel Supernault ce228f7fa4
Update oauth setting, use config_cache 3 years ago
Daniel Supernault d670de175e
Update media_types, use config_cache 3 years ago
Daniel Supernault fecbe1897b
Update pixelfed.max_album_length, use config_cache 3 years ago
Daniel Supernault c96167f2f7
Update config_cache 3 years ago
Daniel Supernault 5e4d4eff9d
Update config cache 3 years ago
Daniel Supernault a4bc5ce3d0
Update web-api popular accounts route to its own method to remove the breaking oauth scope bug 3 years ago
Daniel Supernault 94503a1cf9
Update ApiV1Controller, use admin filter service 3 years ago
Daniel Supernault 3b5500b3a5
Update ApiV1Controller, fix hashtag feed to include private posts from accounts you follow or your own, and your own unlisted posts 3 years ago
Daniel Supernault e3826c587d
Update ApiV1Controller, handle public feed parameter bug to gracefully fallback to min_id=1 when max_id=0 3 years ago
Daniel Supernault d6eac65555
Update ApiV1Controller, fix public timeline scope, properly support both local + remote parameters 3 years ago
Daniel Supernault 6cb1484b3e
cs fix 3 years ago
Daniel Supernault 01535a6cfe
Update ApiV1Controller, improve notification filtering 3 years ago
Daniel Supernault a933615b8d
Update ApiV1Controller, update Notifications endpoint to filter notifications with missing activities 3 years ago
Daniel Supernault 542d110673
Update AccountTransformer, fix follower/following count visibility bug 3 years ago
Daniel Supernault 8dac2caf1d
Add Curated Onboarding 3 years ago
Daniel Supernault 1f74a95d0c
Update ApiV1Controller, implement better limit logic to gracefully handle requests with limits that exceed the max 3 years ago
Daniel Supernault 545f7d5e70
Update api v1/v2 instance endpoints, bump mastoapi version from 2.7.2 to 3.5.3 3 years ago
Daniel Supernault 8b4ac5cc0b
Update public/network timelines, fix non-redis response and fix reblogs in home feed 3 years ago
Daniel Supernault 0faf59e3b7
Update ApiV1Controller, fix network timeline 3 years ago
Daniel Supernault 62b9eef805
Fix api endpoints 3 years ago
Daniel Supernault fd7f5dbba1
Fix api endpoints 3 years ago
Emelia Smith 0f8e45fe75
Implement proper OAuth authorization on API endpoints 3 years ago
Daniel Supernault 5b284cacea
Update ApiV1Controller, enforce blocked instance domain logic 3 years ago
Daniel Supernault 0aff126aa0
Update ApiV1Controller, properly cast boolean sensitive parameter. Fixes #4888 3 years ago
Daniel Supernault fe30cd25d1
Update DirectMessageController, add parental controls support 3 years ago
Daniel Supernault fd9b5ad443
Update api controllers, add parental control support 3 years ago
Daniel Supernault 2dcfc81495
Update ComposeController, add parental controls support 3 years ago
Daniel Supernault 1a16ec2078
Update BookmarkController, add parental control support 3 years ago
Daniel Supernault d25209f74a
Update ApiV1Controller, update favourites max limit. Fixes #4854 3 years ago
Daniel Supernault d39946b045
Update ApiV1Controller, add permissions check 3 years ago
Daniel Supernault 7dbdbf15a5
Add Roles & Parental Controls 3 years ago
Daniel Supernault 89b8e87477
Update ApiV1Controller, apply user domain blocks filtering to hashtag timelines 3 years ago
Daniel Supernault 21947835f8
Update ApiV1Controller, use domainBlock filtering on public/network feeds 3 years ago
Daniel Supernault 60e053c936
Update ApiV1Controller, update discoverAccountsPopular method 3 years ago
Daniel Supernault b641954549
Update ApiV1Controller, set last_active_at 3 years ago
Daniel Supernault aa166ab11a
Update ApiV1Controller, move tags endpoints to TagsController 3 years ago
Daniel Supernault 287f903bf3
Update ApiV1Controller, fix include_reblogs param on timelines/home endpoint, and improve limit pagination logic 3 years ago
Daniel Supernault 19233cc976
Update HashtagFollowObserver 3 years ago
Daniel Supernault c6a6b3ae30
Update Experimental Home Feed, fix remote posts, shares and reblogs 3 years ago
Daniel Supernault b365aa7e06
Update ApiV1Controller 3 years ago
Daniel Supernault 015b1b80b4
Update hashtag following 3 years ago
Daniel Supernault e917341651
Update ApiV1Controller 3 years ago
Daniel Supernault 24c370ee22
Update ApiV1Controller, add experimental home timeline support to v1/timelines/home 3 years ago
Daniel Supernault ddc217147c
Update ApiV1Controller, fix mutes in home feed 3 years ago
Daniel Supernault da510089e2
Update LikePipeline, dispatch to feed queue. Fixes #4723 3 years ago
Daniel Supernault 135798eb68
Update ApiV1Controller, hydrate reblog interactions. Fixes #4686 3 years ago
Daniel Supernault ca746717cb
Update ApiV1Controller, add bookmarked to timeline entities 3 years ago
Daniel Supernault 13bdaa2ed4
Update ApiV1Controller, hydrate reblog state in home timeline 3 years ago
Daniel Supernault 1cc6274ac0
Update rate limits, fixes #4537 3 years ago
Daniel Supernault 37fd03428a
Update ApiV1Controller, add include_reblogs attribute to home timeline 3 years ago
Daniel Supernault fe8728c0ba
Update Direct Messages, fix api endpoint 3 years ago
Daniel Supernault 992d910b9c
Added `following_since` attribute to `/api/v1/accounts/relationships` endpoint when `_pe=1` (pixelfed entity) parameter is present 3 years ago
Daniel Supernault c54cdd3eb4
Update ApiV1Controller, add idempotency-key support to /api/v1/statuses endpoint 3 years ago
Daniel Supernault 79bcaadd49
Update ApiV1Controller, filter muted/blocked accounts from tag timeline. 3 years ago
Daniel Supernault f42c114058
Update ApiV1Controller, filter muted/blocked accounts from tag timeline. 3 years ago
Daniel Supernault 6a2daf1f63
Update ApiControllers, remove cloud ip blocks 4 years ago
Daniel Supernault 167dbcdd43
Add /api/v2/instance api endpoint 4 years ago
Daniel Supernault 0b42fe0f00
Update HashtagService 4 years ago
Daniel Supernault b5fe956acf
Add `only_media` support to /api/v1/timelines/tag/:id api endpoint 4 years ago
Daniel Supernault 521b3b4c82
Add /api/v1/tags/:id api endpoint 4 years ago
Daniel Supernault 4d997bb959
Add /api/v1/tags/:id/follow and /api/v1/tags/:id/unfollow api endpoints 4 years ago
Daniel Supernault 175a848665
Add /api/v1/followed_tags api endpoint 4 years ago
Daniel Supernault fc1a385cfd
Update ApiV1Controller, fix hashtag timeline 4 years ago
Daniel Supernault 6ea2bdc782
Update Admin Dashboard, allow admins to designate an admin account for the landing page and instance api endpoint 4 years ago
Daniel Supernault 37bd2ee51b
Update ApiV1Controller, fix trending accounts format. Closes #4356 4 years ago
Daniel Supernault 055aa6b39f
Update ApiV1Controller and DiscoverController, fix postgres hashtag search 4 years ago
Daniel Supernault d563901622
Update ApiV1Controller 4 years ago