This must return an Array of PaymentInstrumentInterface

@param CustomerInterface $customer
@return array
960421
public function getPaymentInstruments(CustomerInterface $customer): array
    {
        $instrumentClient = new PaymentInstrumentClient($this->getContext(), $this->getOptions());
        $instrumentClient->setCustomer($customer);
        $instrumentClient->setToken($this->getToken());
        $response = $instrumentClient->get();
        $this->setLastResponse($instrumentClient->getLastResponse());

        return $response??[];
    }
1255614
protected function prepareData(RequestInterface $request, User $user)
    {
        $userId = $user->getIdentifier();
        if ($userId === null) {
            $userId = get_class($user);
        }

        return [
            RequestLogService::USER_ID => $userId,
            RequestLogService::USER_ROLES => ','. implode(',', $user->getRoles()). ',',
            RequestLogService::ACTION => $request->getUri()->getPath(),
            RequestLogService::EVENT_TIME => microtime(true),
            RequestLogService::DETAILS => json_encode([
                'method' => $request->getMethod(),
                'query' => $request->getUri()->getQuery(),
            ]),
        ];
    }
771832
public function expandCustomerTransferWithProductListIds(CustomerTransfer $customerTransfer): CustomerTransfer
    {
        $customerTransfer->setCustomerProductListCollection(new CustomerProductListCollectionTransfer());

        $productListCollectionTransfer = $this->productListReader->getProductListCollectionByIdCustomerId(
            $customerTransfer
        );

        $this->addProductListsToCustomerTransfer($customerTransfer, $productListCollectionTransfer);

        return $customerTransfer;
    }
939072
public function getCustomerDebts($customer = null)
    {
        switch (gettype($customer)) {
            case 'object':
                if (get_class($customer) == 'Customer') {
                    $firma = $customer->adresa;
                } else {
                    $firma = $customer;
                }
                break;
            case 'NULL':
                $firma = $this->adresar;
                break;
            default:
            case 'string':
            case 'int':
                $firma = $customer;
                break;
        }

        if (!is_object($this->invoicer)) {
            $this->invoicer = new \FlexiPeeHP\FakturaVydana();
        }
        $result                                    = [];
        $this->invoicer->defaultUrlParams['order'] = 'datVyst@A';
        $invoices                                  = $this->invoicer->getColumnsFromFlexibee([
            'id',
            'kod',
            'stavUhrK',
            'firma',
            'buc',
            'varSym',
            'specSym',
            'sumCelkem',
            'duzpPuv',
            'typDokl(typDoklK,kod)',
            'datSplat',
            'zbyvaUhradit',
            'mena',
            'zamekK',
            'datVyst'],
            ["datSplat lte '".\FlexiPeeHP\FlexiBeeRW::dateToFlexiDate(new \DateTime())."' AND (stavUhrK is null OR stavUhrK eq 'stavUhr.castUhr') AND storno eq false AND firma=".$firma],
            'kod');

        if ($this->invoicer->lastResponseCode == 200) {
            $result = $invoices;
        }
        return $result;
    }
1051340
public function getCustomerLastOrderId(\Magento\Customer\Model\Customer $customer)
    {
        $storeIds = $this->storeManager->getWebsite(
            $customer->getWebsiteId()
        )->getStoreIds();

        return $this->orderCollection->create()
            ->getCustomerLastOrderId($customer, $storeIds);
    }
626013
public function get()
    {
        if ($this->customer instanceof CustomerInterface) {
            return $this->customer;
        }

        $customer = $this->getCustomerFromToken();

        if (null === $customer) {
            $customer = $this->customerFactory->create();
        }

        $this->customer = $customer;

        return $customer;
    }
631530
protected function getCommandArguments(InputInterface $input)
    {
        $package = $this->getPackageInformation($input->getOption('package'));

        return [
            $this->getComposer(),
            $this->composerOperation,
            $package,
        ];
    }
382476
public function disablePaymentInstrument(
        CustomerInterface $customer,
        PaymentInstrumentInterface $paymentInstrument
    ): bool
    {
        $instrumentClient = new PaymentInstrumentClient($this->getContext(), $this->getOptions());
        $instrumentClient->setCustomer($customer);
        $instrumentClient->setToken($this->getToken());
        $response = $instrumentClient->disable($paymentInstrument);
        $this->setLastResponse($instrumentClient->getLastResponse());

        return $response??false;
    }
548038
public function getPivot(RecordInterface $record): array
    {
        if (empty($matched = $this->matchOne($record))) {
            return [];
        }

        return $this->pivotData->offsetGet($matched);
    }
894984
public function getCustomer($customerId)
    {
        /** @var CustomerFbApi $response */
        $response = $this->call(new Request('customer.get', array('customer_id' => $customerId)), 'DVelopment\FastBill\Model\CustomerFbApi');
        $customers = $response->getResponse()->getCustomers();

        return reset($customers);
    }
731210
protected function getUserThrottles(UserInterface $user)
    {
        $key = $user->getUserId();

        if (! array_key_exists($key, $this->userThrottles)) {
            $this->userThrottles[$key] = $this->loadUserThrottles($user);
        }

        return $this->userThrottles[$key];
    }
746008
public function buildCustomerCollection($customerIds)
    {
        $customerLog = $this->getTable('customer_log');
        $customerCollection = $this->customerCollection->create()
            ->addAttributeToSelect('*')
            ->addNameToSelect();
        $customerCollection = $this->addBillingJoinAttributesToCustomerCollection($customerCollection);
        $customerCollection = $this->addShippingJoinAttributesToCustomerCollection($customerCollection);
        $customerCollection = $customerCollection->addAttributeToFilter('entity_id', ['in' => $customerIds]);

        // get the last login date from the log_customer table
        $customerCollection->getSelect()->columns([
            'last_logged_date' => $this->expressionFactory->create(
                ["expression" => "(
                    SELECT last_login_at 
                    FROM  $customerLog 
                    WHERE customer_id =e.entity_id ORDER BY log_id DESC LIMIT 1
                )"]
            ),
        ]);

        return $customerCollection;
    }
849666
public function dispatchOnCustomerRegisteredEvent(CustomerInterface $customer)
    {
        $event = new CustomerRegisterEvent($customer);
        $this
            ->eventDispatcher
            ->dispatch(
                ElcodiUserEvents::CUSTOMER_REGISTER,
                $event
            );

        return $this;
    }
1358236
public function register(ClientInterface $client)
    {
        $client = $this->decorate($client);

        array_push($this->clients, $client);

        return $client;
    }
878596
private function getRoles(ApiUserInterface $user)
    {
        $roles = $user->getRoles();
        if ($user->getApiKeyEnabled()) {
            $roles[] = $this->apiUserRole;
        }

        return $roles;
    }
458799
public function getSupportedMethods(ShippingSubjectInterface $subject): array
    {
        /** @var ShipmentInterface $subject */
        Assert::isInstanceOf($subject, ShipmentInterface::class);
        Assert::true($this->supports($subject));

        /** @var OrderInterface $order */
        $order = $subject->getOrder();

        $zones = $this->zoneMatcher->matchAll($order->getShippingAddress(), Scope::SHIPPING);
        if (empty($zones)) {
            return [];
        }

        $methods = [];

        $shippingMethods = $this->shippingMethodRepository->findEnabledForZonesAndChannel($zones, $order->getChannel());
        foreach ($shippingMethods as $shippingMethod) {
            if ($this->eligibilityChecker->isEligible($subject, $shippingMethod)) {
                $methods[] = $shippingMethod;
            }
        }

        return $methods;
    }
1278193
public function getProductListCustomerRelation(
        ProductListCustomerRelationTransfer $productListCustomerRelationTransfer
    ): ProductListCustomerRelationTransfer {
        $productListCustomerRelationTransfer->requireIdProductList();

        $customerIds = $this->productListCustomerRepository->getRelatedCustomerIdsByIdProductList(
            $productListCustomerRelationTransfer->getIdProductList()
        );

        $productListCustomerRelationTransfer->setCustomerIds($customerIds);

        return $productListCustomerRelationTransfer;
    }