aboutsummaryrefslogtreecommitdiffstats
path: root/core/Controller/ReferenceApiController.php
Commit message (Collapse)AuthorAgeFilesLines
* refactor(core): Replace security annotations with respective attributesprovokateurin2024-07-261-16/+10
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* fix(ReferenceApiController): Remove accidently added AnonRateLimitJonas2024-07-171-1/+0
| | | | Signed-off-by: Jonas <jonas@freesources.org>
* feat(Reference): Add public API endpoints to get referencesJonas2024-07-171-0/+89
| | | | | | | | | | | | | | | | | | | | | | | Calling the public API endpoints will check for matching registered reference providers that implement `IPublicReferenceProvider` and call their respective functions. If no matching provider is found, the default `LinkReferenceProvider` will be used to provide open graph data. The frontend reference widget components will call these endpoints from unauthorized sessions, e.g. in public shares. If present, the sharing token of the origin URL is passed to `resolveReferencePublic()` as additional information for the reference provider to determine the access scope. This allows the respective reference providers to determine whether the origin share has access to the linked resource. `getCacheKeyPublic` also gets the sharing token so it can scope the cached entry to it. Contributes to #45978 Signed-off-by: Jonas <jonas@freesources.org>
* fix(core): use OC namespace for core ReponseDefinitions instead of OCAJulien CHATY-CAPELLE2024-07-151-1/+1
| | | | Signed-off-by: Julien CHATY-CAPELLE <julien@chaty-capelle.fr>
* chore: Add SPDX headerAndy Scherzinger2024-05-271-19/+2
| | | | Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
* refactor(core): Switch to attribute based routingprovokateurin2024-02-211-0/+6
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* Add single status code descriptions for OpenAPIjld31032023-09-271-0/+10
| | | | Signed-off-by: jld3103 <jld3103yt@gmail.com>
* core: Fix OpenAPI for reference APIjld31032023-09-141-2/+2
| | | | Signed-off-by: jld3103 <jld3103yt@gmail.com>
* core: Add OpenAPI specjld31032023-07-131-6/+41
| | | | Signed-off-by: jld3103 <jld3103yt@gmail.com>
* Applies agreed-upon indentation convention to the changed controllers.Faraz Samapoor2023-06-161-4/+6
| | | | | | Based on https://github.com/nextcloud/server/pull/38636#discussion_r1218167753 Signed-off-by: Faraz Samapoor <f.samapoor@gmail.com>
* Refactors controllers by using PHP8's constructor property promotion.Faraz Samapoor2023-06-161-7/+2
| | | | Signed-off-by: Faraz Samapoor <f.samapoor@gmail.com>
* handle and return touchProvider errorsJulien Veyssier2023-01-271-7/+3
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* add 'last used timestamp' management for reference providersJulien Veyssier2023-01-271-1/+19
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* extend the reference API for the new link pickerJulien Veyssier2023-01-271-0/+14
| | | | | | | | | - add 2 interfaces for discoverable and searchable reference providers - new OCS route to get info on discoverable/searchable reference providers - new abstract ADiscoverableReferenceProvider that only implements jsonSerialize - listen to RenderReferenceEvent to inject provider list with initial state Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* Fix URLs on reference resolvingJoas Schilling2022-09-301-1/+1
| | | | | | The vue-richtext app currently sends leading spaces if they are in the text. Signed-off-by: Joas Schilling <coding@schilljs.com>
* Add endpoint to fetch a cachable reference dataJulius Härtl2022-09-261-0/+10
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Refactor cache handlingJulius Härtl2022-08-311-2/+4
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* CleanupJulius Härtl2022-08-311-11/+8
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Implement image cachingJulius Härtl2022-08-311-0/+82
Signed-off-by: Julius Härtl <jus@bitgrid.net>