// flynt-disable missing-service-entity, missing-permission
syntax = "proto3";

package com.wixpress.authorization;

import "wix/api/validations.proto";
import "wix/api/annotations.proto";

message TriggerGdprDeleteUserDataResponse {
}

message TriggerGdprDeleteUserDataRequest {
    //invited user id
    string userGuid = 1 [(wix.api.format) = GUID];
    //RightToBeDeletedRequest id
    string requestId = 2 [(wix.api.format) = GUID];
}

message MigrateInviteRequest {
    string invite_id = 1;
}

message MailAndAccountId {
    string mail = 1 [(.wix.api.pii) = true];
    string account_id = 2;
}

message DeleteAccountInviteRequest {
    oneof By {
        string invite_id = 1;
        MailAndAccountId mail_and_account = 2;
    }
}

message DeleteAccountInvitesRequest {
    string account_id = 1 [(wix.api.format) = GUID];
    bool hard_delete = 2;
}

message EmptyResponse { }

service AuthorizationServiceDevApi {
    option (.wix.api.service_exposure) = PRIVATE;

    rpc triggerGdprDeleteUserData (TriggerGdprDeleteUserDataRequest) returns (TriggerGdprDeleteUserDataResponse);
    rpc migrateInviteToAccount (MigrateInviteRequest) returns (EmptyResponse);
    rpc deleteAccountInvite (DeleteAccountInviteRequest) returns (EmptyResponse);
    rpc deleteAccountInvites (DeleteAccountInvitesRequest) returns (EmptyResponse);
}
