move the API key in meilisearch_types

This commit is contained in:
Tamo 2022-10-12 16:10:28 +02:00 committed by Clément Renault
parent c192146fbe
commit 7034803712
No known key found for this signature in database
GPG key ID: 92ADA4E935E71FA4
12 changed files with 407 additions and 246 deletions

View file

@ -138,9 +138,9 @@ pub mod policies {
use uuid::Uuid;
use crate::extractors::authentication::Policy;
use meilisearch_auth::{Action, AuthController, AuthFilter, SearchRules};
use meilisearch_auth::{AuthController, AuthFilter, SearchRules};
// reexport actions in policies in order to be used in routes configuration.
pub use meilisearch_auth::actions;
pub use meilisearch_types::keys::{actions, Action};
fn tenant_token_validation() -> Validation {
let mut validation = Validation::default();

View file

@ -6,8 +6,9 @@ use serde_json::Value;
use time::OffsetDateTime;
use uuid::Uuid;
use meilisearch_auth::{error::AuthControllerError, Action, AuthController, Key};
use meilisearch_auth::{error::AuthControllerError, AuthController};
use meilisearch_types::error::{Code, ResponseError};
use meilisearch_types::keys::{Action, Key};
use crate::extractors::{
authentication::{policies::*, GuardedData},