Commit graph

5874 commits

Author SHA1 Message Date
rinpatch 158f9f18ee Merge branch 'remove-conversation-api' into 'develop'
Add API endpoint to remove a conversation

Closes #2488

See merge request pleroma/pleroma!3321
2021-02-17 15:14:27 +00:00
rinpatch d7ad288c84 Chats: Introduce /api/v2/pleroma/chats which implements pagination
Also removes incorrect claim that /api/v1/pleroma/chats supports
pagination and deprecates it.

Closes #2140
2021-02-17 16:03:24 +03:00
rinpatch 98ab2b82a6 ChatMessage schema: Add unread property
It is present in the code, but was not documented.
2021-02-16 22:41:06 +03:00
Ivan Tashkinov 1dac7d1462 [#3213] Fixed hashtags.name lookup (must use citext type to do index scan). Fixed embedded hashtags lookup (lowercasing), adjusted tests. 2021-02-15 21:13:14 +03:00
Egor Kislitsyn cf6d3db58f
Add API endpoint to remove a conversation 2021-02-15 21:48:13 +04:00
Mark Felder 9b61df1fb6 App is already preloaded into the token, so avoid an extra query 2021-02-12 12:44:45 -06:00
Mark Felder c1d78328ee Consistency 2021-02-11 14:27:52 -06:00
Mark Felder 6dc0b13cf8 Revert to original formatting for these function defs 2021-02-11 14:24:51 -06:00
Mark Felder 7c508319a5 Prefer naming this put_application because we're putting it into the params map 2021-02-11 14:19:53 -06:00
Mark Felder 09b8378646 %Token{} may not be in the conn, so avoid breaking the ability to post statuses in that scenario. 2021-02-11 14:15:25 -06:00
Ivan Tashkinov 5992382cf8 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework
# Conflicts:
#	CHANGELOG.md
#	lib/mix/tasks/pleroma/database.ex
#	lib/pleroma/web/templates/feed/feed/_activity.rss.eex
2021-02-11 19:31:57 +03:00
Ivan Tashkinov df89b5019b [#2510] Improved support for app-bound OAuth tokens. Auth-related refactoring. 2021-02-11 15:02:50 +03:00
Haelwenn 2cf753c502 Merge branch 'fix/no-version-api-pleroma-social' into 'develop'
Fix no version number on api.pleroma.social

See merge request pleroma/pleroma!3310
2021-02-10 00:52:59 +00:00
Mark Felder 4540e08a6a Rendering fallback for when we don't have valid data available 2021-02-09 18:52:22 -06:00
Mark Felder 981349f21d Enable rendering of the client application data details 2021-02-09 18:22:41 -06:00
Mark Felder 3dc7e89c54 Ensure we capture the application details into the object 2021-02-09 18:07:15 -06:00
Mark Felder de8b8e9cf1 Add a function to lookup client app details by the app_id 2021-02-09 16:59:58 -06:00
rinpatch a853218701 Merge branch 'features/ap_id-c2s-authentication' into 'develop'
activity_pub_controller: Add authentication to object & activity endpoints

See merge request pleroma/pleroma!3295
2021-02-09 19:29:43 +00:00
rinpatch 0d9230aed9 OpenAPI spec: Do not show build enviroment in the spec version 2021-02-09 22:23:11 +03:00
feld 593c0851d9 Merge branch 'develop' into 'new-user-emails' 2021-02-08 16:01:50 -06:00
Haelwenn a5bee1bf35 Merge branch 'feat/mrf-noemptypolicy' into 'develop'
MRF NoEmptyPolicy: Deny posts from local users if there is no content or only mentions.

See merge request pleroma/pleroma!3309
2021-02-08 21:49:20 +00:00
Mark Felder 55a13fc360 MRF NoEmptyPolicy: Deny posts from local users if there is no content or only mentions.
Helps prevent accidental button mashes from submitting incomplete posts
2021-02-08 15:32:47 -06:00
rinpatch 17f41a589f Merge branch 'fix/rss-link' into 'develop'
RSS: Make sure post URL is the first `<link>` element

See merge request pleroma/pleroma!3308
2021-02-08 20:14:53 +00:00
rinpatch ed8ef80b5e RSS: Make sure post URL is the first <link> element
Otherwise some RSS readers (tested in Miniflux) might pick the context
URL as the external link.

Related to #2425.
2021-02-08 22:44:15 +03:00
Haelwenn (lanodan) Monnier 8c7b3b20d8
activity_pub_controller: Add authentication to object & activity endpoints 2021-02-08 20:00:47 +01:00
Ivan Tashkinov d1c6dd97aa [#3213] Partially addressed code review points.
migration rollback task changes, hashtags-related config handling tweaks, `hashtags.data` deletion (unused).
2021-02-07 22:24:12 +03:00
Mark Felder af37a5c51a Also make this maybe_ for consistency 2021-02-04 14:33:49 -06:00
Mark Felder d047372291 Merge branch 'develop' into fix/reports-from-admins 2021-02-04 12:37:20 -06:00
feld 7b67bf4e97 Merge branch 'fix/configdb-error' into 'develop'
Improve error message for ConfigDB

See merge request pleroma/pleroma!3289
2021-02-04 14:33:59 +00:00
Haelwenn ea5469961a Merge branch 'bugfix/notice-external-redirect' into 'develop'
Redirect non-local activities when /notice/:id is used

See merge request pleroma/pleroma!3300
2021-02-04 14:26:03 +00:00
Haelwenn (lanodan) Monnier ecff027418
Redirect non-local activities when /notice/:id is used
Related-to: https://git.pleroma.social/pleroma/pleroma/-/issues/2496
2021-02-04 15:17:40 +01:00
Mark Felder 76f732766b Exclude reporter from receiving notifications from their own reports.
Currently only works if the reporting actor is an admin, but if we include
moderators with those who receive notification reports it will work for them.
2021-02-03 12:32:44 -06:00
rinpatch 74ef1a044d Account schema: specify that pleroma.relationship is nullable 2021-02-03 18:10:43 +03:00
feld 008499f65a Merge branch 'develop' into 'fix/2412-filters'
# Conflicts:
#   CHANGELOG.md
2021-02-03 14:23:23 +00:00
feld c3dd860a02 Merge branch 'fix/2449-scheduled-poll-bug' into 'develop'
Fix for scheduled post with poll

Closes #2449

See merge request pleroma/pleroma!3294
2021-02-03 14:22:23 +00:00
feld 8d2ea95402 Merge branch 'feature/2438-users-posts-total-count' into 'develop'
Feature/2438 users/instances posts total count

Closes #2438

See merge request pleroma/pleroma!3270
2021-02-03 14:21:57 +00:00
rinpatch e2d7c4fd57 Merge branch 'feat/openapi-spec-export' into 'develop'
Improve OpenAPI spec and deploy it to api.pleroma.social

See merge request pleroma/pleroma!3296
2021-02-03 13:21:19 +00:00
rinpatch 9fcff7851f Improve OpenAPI spec and deploy it to api.pleroma.social
Too many changes in OpenAPI spec to describe each one, but
basically it is tag fixes, bringing consitency to operation summaries
and fixing some incorrect information.
2021-02-03 16:07:44 +03:00
Ivan Tashkinov 4e14945670 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework
# Conflicts:
#	CHANGELOG.md
#	lib/pleroma/web/activity_pub/activity_pub.ex
2021-02-03 09:31:38 +03:00
feld f1f773f2c7 Merge branch 'email-stub-in-verify-credentials' into 'develop'
Email-like field in /api/v1/accounts/verify_credentials (for PeerTube OAuth plugin and alike)

See merge request pleroma/pleroma!3286
2021-02-02 18:35:08 +00:00
feld d289ad8579 Merge branch 'develop' into 'fix/2411-mutes-api'
# Conflicts:
#   CHANGELOG.md
#   docs/development/API/differences_in_mastoapi_responses.md
2021-02-02 17:57:58 +00:00
feld cd5ff7a943 Merge branch 'develop' into 'feature/2164-unify-api-arguments'
# Conflicts:
#   CHANGELOG.md
2021-02-02 17:11:38 +00:00
feld 69c560cfba Merge branch 'active-user-count' into 'develop'
Monthly Active Users

Closes #2332

See merge request pleroma/pleroma!3283
2021-02-02 17:07:57 +00:00
Alexander Strizhakov 0dc68c157f
fix for scheduled post with poll 2021-02-01 18:22:26 +03:00
Alexander Strizhakov fdf1dfed56
only_remote -> remote renaming 2021-02-01 14:11:12 +03:00
Alexander Strizhakov ba512cbea4
/api/v1/accounts/:id/statuses docs update 2021-02-01 14:11:12 +03:00
Alexander Strizhakov 77f0a0af7d
more tests and update for docs and changelog 2021-02-01 14:11:12 +03:00
Alexander Strizhakov 2cb6dc5a3a
list timeline filtration by params 2021-02-01 14:11:12 +03:00
Alexander Strizhakov b6a72680e2
added only_media flag to home timeline 2021-02-01 14:11:11 +03:00
Alexander Strizhakov c3110c46f3
expanding filtration for home timeline
added local & remote statuses filtration for home timeline
2021-02-01 14:11:11 +03:00
Ivan Tashkinov cf4765af40 [#3213] ActivityPub: fixed subquery-based hashtags filtering implementation (addressed empty list options issue). Added regression test. 2021-01-31 23:06:38 +03:00
Ivan Tashkinov 10207f840c [#3213] ActivityPub: temporarily reverted to previous hashtags filtering implementation due to blank results issue. 2021-01-31 22:36:46 +03:00
Ivan Tashkinov 1b49b8efe5 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework
# Conflicts:
#	CHANGELOG.md
2021-01-31 20:38:58 +03:00
Ivan Tashkinov 6fd4163ab6 [#3213] ActivityPub: implemented subqueries-based hashtags filtering, removed aggregation-based hashtags filtering. 2021-01-31 20:37:33 +03:00
Alexander Strizhakov b794dae98a
like this 2021-01-29 15:55:00 +03:00
Alexander Strizhakov c369d2b930
support for with_relationships parameter
in /api/v1/mutes and /api/v1/accounts/:id endpoints
2021-01-29 08:41:21 +03:00
Ivan Tashkinov 380d0cce6b [#3213] Reinstated DISTINCT clause for hashtag "any" filtering with 2+ terms. Added test. 2021-01-29 00:17:33 +03:00
Mark Felder 5fcab23aa3 Improve error message for ConfigDB 2021-01-28 14:59:23 -06:00
Ivan Tashkinov 60b4654038 Email-like field in /api/v1/accounts/verify_credentials response (for OAuth plugins like Peertube).
Addresses https://git.pleroma.social/pleroma/pleroma-support/-/issues/56.
2021-01-28 19:49:43 +03:00
Alexander Strizhakov 35cad9793d
cache headers for emoji and images 2021-01-27 18:49:08 +03:00
Egor Kislitsyn 793fc77b16
Add active user count 2021-01-27 18:20:06 +04:00
Alexander Strizhakov d4158e8bf0
added total
to the instance adminAPI endpoint
2021-01-27 07:45:06 +03:00
Alexander Strizhakov 6806c03e85
added total
to the user statuses adminAPI endpoint
2021-01-27 07:45:02 +03:00
feld d7af0294e6 Merge branch 'service-worker-allowed-header' into 'develop'
Ability to set custom HTTP headers per each frontend

See merge request pleroma/pleroma!3247
2021-01-26 18:14:01 +00:00
Alexander Strizhakov 875fbaae35
support for expires_in/expires_at in filters 2021-01-26 08:27:45 +03:00
Haelwenn 250e202098 Merge branch 'fix/missing-own_votes' into 'develop'
Include own_votes in the poll data

See merge request pleroma/pleroma!3274
2021-01-26 00:55:05 +00:00
Mark Felder 2cb5c16723 Credo 2021-01-25 18:25:53 -06:00
Mark Felder 0b19534475 Merge branch 'develop' into docs/apache-config 2021-01-25 17:00:26 -06:00
Ivan Tashkinov e7864a32d7 [#3213] Removed DISTINCT clause from ActivityPub.fetch_activities_query/2. 2021-01-25 22:31:23 +03:00
Ivan Tashkinov 694d98be55 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework 2021-01-25 21:24:07 +03:00
Alexander Strizhakov 3f3d64acbf
little refactor and tests
for voted & own_votes fields in polls
2021-01-25 19:46:36 +03:00
Mark Felder 537ba1c5e0 Merge branch 'develop' into refactor/deactivated_user_field 2021-01-25 09:45:06 -06:00
Mark Felder 6bfd497f4a Include own_votes in the poll data 2021-01-22 09:47:59 -06:00
Ivan Tashkinov 218c519606 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework
# Conflicts:
#	test/pleroma/web/mastodon_api/views/status_view_test.exs
2021-01-22 10:05:28 +03:00
Mark Felder 80ccdb56f6 Make tag urls absolute 2021-01-21 16:49:19 -06:00
Mark Felder e5b32aab92 rename function 2021-01-21 14:41:28 -06:00
Mark Felder 003402df40 Add ability to invalidate cache entries for Apache 2021-01-21 14:20:13 -06:00
eugenijm 7fcaa188a0 Allow to define custom HTTP headers per each frontend 2021-01-21 21:55:23 +03:00
eugenijm 133644dfa2 Ability to set the Service-Worker-Allowed header 2021-01-21 21:55:11 +03:00
Ivan Tashkinov c041e9c630 [#3213] HashtagsTableMigrator: failures handling fix, retry function.
Changed default hashtags filtering strategy to non-aggregate approach.
2021-01-21 20:23:08 +03:00
Ivan Tashkinov 2634a16b4c Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework
# Conflicts:
#	CHANGELOG.md
2021-01-21 20:20:35 +03:00
Alexander Strizhakov 6d48144a9d
use proper naming
for MediaProxyWarmingPolicy in ConcurrentLimiter
2021-01-21 09:50:18 +03:00
feld 958a7f6ed0 Merge branch 'fix/reblog-api' into 'develop'
Fix Reblog API

Closes #2423

See merge request pleroma/pleroma!3261
2021-01-18 21:19:14 +00:00
Mark Felder 28581e03ad Merge branch 'develop' into refactor/deactivated_user_field 2021-01-18 14:58:21 -06:00
Mark Felder 44a86951a3 Merge branch 'develop' into refactor/approval_pending_user_field 2021-01-18 12:05:05 -06:00
Egor Kislitsyn 1b79dce7bc
Fix Reblog API
Do not set visibility parameter to `public` by default and let CommonAPI to infer it from status.
2021-01-18 20:15:57 +04:00
Ivan Tashkinov 48b399cedb [#3213] Refactoring of HashtagsTableMigrator. Hashtag timeline performance optimization (auto switch to non-aggregate join strategy when efficient). 2021-01-16 20:22:14 +03:00
Mark Felder 2c0fe2ea9e Remove toggle_confirmation; require explicit state change
Also cosmetic changes to make the code clearer
2021-01-15 13:11:51 -06:00
Mark Felder d36182c088 Change user.confirmation_pending field to user.is_confirmed 2021-01-15 12:44:41 -06:00
Mark Felder ebd7d1365b Make setting user activation status explicit 2021-01-15 11:37:17 -06:00
Mark Felder 860b5c7804 Change user.deactivated field to user.is_active 2021-01-15 11:24:46 -06:00
Mark Felder f7e59c28ed Change user.approval_pending field to user.is_approved 2021-01-15 10:42:02 -06:00
Lain Soykaf 39f3683a06 Pbkdf2: Use it everywhere. 2021-01-14 15:06:16 +01:00
Ivan Tashkinov e350898828 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework 2021-01-13 22:11:16 +03:00
Ivan Tashkinov 3e4d84729a [#3213] Prototype of data migrations functionality / HashtagsTableMigrator. 2021-01-13 22:07:38 +03:00
lain 9106048c61 Password: Replace Pbkdf2 with Password. 2021-01-13 15:11:11 +01:00
Haelwenn (lanodan) Monnier c4439c630f
Bump Copyright to 2021
grep -rl '# Copyright © .* Pleroma' * | xargs sed -i 's;Copyright © .* Pleroma .*;Copyright © 2017-2021 Pleroma Authors <https://pleroma.social/>;'
2021-01-13 07:49:50 +01:00
feld 5453038ce9 Merge branch 'fix/backup-url-on-s3' into 'develop'
Standardize base url for uploads

See merge request pleroma/pleroma!3246
2021-01-12 20:54:30 +00:00
lain 7a1cb752dd Pagination: Don't be dos'd by random parameters. 2021-01-12 12:59:50 +01:00
Mark Felder ef59d99833 Simplify. We will always have a result from Upload.base_url/0, so just add it to the list 2021-01-11 14:19:14 -06:00