@symanticreative/vendure-admin-client
Version:
A TypeScript GraphQL client for Vendure Admin API to create custom dashboards
35 lines (34 loc) • 1.28 kB
TypeScript
import { BasePaginatedService } from './base.service';
import { CustomerRepository } from '../repositories/customer.repository';
import { Customer, CreateCustomerInput, UpdateCustomerInput } from '../models/customer.model';
/**
* Service for customer operations
*/
export declare class CustomerService extends BasePaginatedService<Customer, string> {
constructor(customerRepository: CustomerRepository);
/**
* Create a new customer
* @param input - Customer creation input
* @returns Promise resolving to created customer
*/
createCustomer(input: CreateCustomerInput): Promise<Customer>;
/**
* Update an existing customer
* @param input - Customer update input
* @returns Promise resolving to updated customer
*/
updateCustomer(input: UpdateCustomerInput): Promise<Customer>;
/**
* Get customer by email
* @param email - Customer email
* @returns Promise resolving to customer or null
*/
getCustomerByEmail(email: string): Promise<Customer | null>;
/**
* Search customers
* @param term - Search term
* @param options - Pagination options
* @returns Promise resolving to paginated customers
*/
searchCustomers(term: string, options?: any): Promise<any>;
}