lupasearch/lupasearch-php-client 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

lupasearch/lupasearch-php-client

最新稳定版本:0.5.3

Composer 安装命令:

composer require lupasearch/lupasearch-php-client

包简介

LupaSearch API PHP Client

README 文档

README

  • Current client version: v0.5.3
  • Supports PHP ^7.2

Getting Started

Authentication and authorization

Initiate client object and set the API key for authorization (recommended).

$client = new \LupaSearch\LupaClient(); $client->setApiKey("your_api_key_here"); 

Alternatively, you can use email and password credentials for authentication and JWT token for authorization.

$client = new \LupaSearch\LupaClient(); $client ->setEmail('account@search.com') ->setPassword('password') ->authenticate(); 

Data indexing

Import documents into search index:

$indexId = '7a31899f-31bc-46ac-b782-a44d71c5d622'; $documents = [ 'documents' => [ [ 'id' => 1, 'name' => 'Bag', 'category' => 'Bags' ], [ 'id' => '2', 'name' => 'Glasses', 'price' => 9.99, 'category' => 'Accessories' ] ] ]; $lupaDocumentsApi = new \LupaSearch\Api\DocumentsApi($client); $importResponse = $lupaDocumentsApi->importDocuments( $indexId, $documents ); 

Track progress of asynchronous tasks:

$lupaTasksApi = new \LupaSearch\Api\TasksApi($client); $tasks = $lupaTasksApi->getTasks($indexId, [ 'batchKey' => $importResponse['batchKey'] ]); 

Search

Send search request:

$publicQueryKey = 'qraljpj1reo9'; $lupaPublicQueriesApi = new \LupaSearch\Api\PublicQueryApi($client); $searchResponse = $lupaPublicQueriesApi->search($queryKey, [ 'searchText' => '', 'filters' => ['category' => ['Accessories']] ]); 

Resources

统计信息

  • 总下载量: 19.09k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 3
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固