{"id":33988557,"url":"https://github.com/sch-group/pickpoint-sdk","last_synced_at":"2025-12-13T05:59:17.613Z","repository":{"id":45636150,"uuid":"198599816","full_name":"sch-group/pickpoint-sdk","owner":"sch-group","description":"Pickpoint delivery api connector","archived":false,"fork":false,"pushed_at":"2021-12-03T14:13:13.000Z","size":80,"stargazers_count":8,"open_issues_count":0,"forks_count":5,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-29T03:37:20.616Z","etag":null,"topics":["php","pickpoint","pickpoint-sdk"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sch-group.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-07-24T09:11:55.000Z","updated_at":"2023-05-03T14:12:10.000Z","dependencies_parsed_at":"2022-08-12T12:00:14.334Z","dependency_job_id":null,"html_url":"https://github.com/sch-group/pickpoint-sdk","commit_stats":null,"previous_names":[],"tags_count":34,"template":false,"template_full_name":null,"purl":"pkg:github/sch-group/pickpoint-sdk","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sch-group%2Fpickpoint-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sch-group%2Fpickpoint-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sch-group%2Fpickpoint-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sch-group%2Fpickpoint-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sch-group","download_url":"https://codeload.github.com/sch-group/pickpoint-sdk/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sch-group%2Fpickpoint-sdk/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27701296,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-12-13T02:00:09.769Z","response_time":147,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["php","pickpoint","pickpoint-sdk"],"created_at":"2025-12-13T05:59:16.934Z","updated_at":"2025-12-13T05:59:17.596Z","avatar_url":"https://github.com/sch-group.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"API PICKPOINT PHP SDK\n\nhttps://pickpoint.ru/sales/api/\n\n@ainurecm telegram\n\n```bash\ncomposer require sch-group/pickpoint\n```\nПримеры: \n\nИнициализация\n```\n$config = [\n 'host' =\u003e '',\n 'login' =\u003e '',\n 'password' =\u003e '',\n 'ikn' =\u003e '',\n];    \n\n$pickPointConf = new PickPointConf($config['host'], $config['login'], $config['password'], $config['ikn']);\n\n$defaultPackageSize = new PackageSize(20, 20,20); // может быть null\n\n$senderDestination = new SenderDestination('Москва', 'Московская обл.'); // Адрес отправителя\n\n$client = new PickPointConnector($pickPointConf, $senderDestination, $defaultPackageSize);\n \n \nТак же можно добавить кэширование, для ускорения запроса на авторизацию \n$redisCacheConf = [\n 'host' =\u003e '127.0.0.1',\n 'port' =\u003e 6379\n];\n\n$client = new PickPointConnector($pickPointConf, $senderDestination, $defaultPackageSize, $redisCacheConf);\n\n \n```\n\nПолучение массива постаматов\n\n```\n$points = $client-\u003egetPoints(); // get postamats list\n\n```\nЦены за доставку\n\n```\n$receiverDestination = new ReceiverDestination('Санкт-Петербург', 'Ленинградская обл.');\n\n$prices = $client-\u003ecalculatePrices($receiverDestination); // вернет массив с ценами и тарифами\n\n$tariffPrice = $client-\u003ecalculateObjectedPrices($receiverDestination); // Вернет объект с ценами\n\n$commonStandardPrice = $tariffPrice-\u003egetStandardCommonPrice(); // получить общую цену с тарифом стандарт\n```\nСоздание отправления \n```\n$invoice = new Invoice();\n$invoice-\u003esetSenderCode('order: 123456');\n$invoice-\u003esetPostamatNumber('5602-009');\n$invoice-\u003esetDescription('Custom zakaz');\n$invoice-\u003esetRecipientName('Саша');\n$invoice-\u003esetMobilePhone('+79274269590');\n$invoice-\u003esetEmail('kek@mail.ru');\n$invoice-\u003esetGettingType('sc'); // courier or sc\n$invoice-\u003esetSum(500.00);\n$invoice-\u003esetDeliveryMode('standard'); // stanadard or priority\n$packageSize = new PackageSize(20, 20, 20);\n$invoice-\u003esetPackageSize($packageSize);\n\n$product = new Product('number 234', 'Test', 2, 100);\n\n$address = new Address();\n$address-\u003esetCityName('Казань');\n$address-\u003esetPhoneNumber('+79274269590');\n$invoice-\u003esetClientReturnAddress($address);\n$response = $client-\u003ecreateShipment($invoice);\n```\nПечать наклейки\n```\n$invoice = $client-\u003ecreateShipmentWithInvoice($invoice);\n$invoiceNumber = $invoice-\u003egetInvoiceNumber();\n$pdfByteCode = $client-\u003eprintLabel(array($invoiceNumber));\n```\nСоздание реестра и печать\n```\n$invoice = $client-\u003ecreateShipmentWithInvoice($invoice);\n$invoiceNumber = $invoice-\u003egetInvoiceNumber();\n\n$reestr = $client-\u003emakeReceipt(array($invoiceNumber));\n$pdfByteCode = $client-\u003erintReceipt($reestr[0]);\n\n```\nОдновременное создание реестра и печать\n```\n$invoice = $client-\u003ecreateShipmentWithInvoice($invoice);\n$invoiceNumber = $invoice-\u003egetInvoiceNumber();\n$pdfByteCode = $client-\u003emakeReceiptAndPrint(array($invoiceNumber));\n```\nУдалить инвойс из реестра\n```\n $remove = $client-\u003eremoveInvoiceFromReceipt($invoiceNumber);\n```\nПроверка статуса отправлений\n\n```\n$invoiceNumber = $invoice-\u003egetInvoiceNumber();\n$status = $client-\u003egetStatus($invoiceNumber);\n$status-\u003egetState();\n$status-\u003egetStateText();\n```\nПолучить все статусы\n\n```\n$states = $client-\u003egetStates();\n```\n\nОтмена отправления \n\n```\n$senderCode = $invoice-\u003egetSenderCode(); // order id\n$cancelResponse = $client-\u003ecancelInvoice($invoiceNumber);\nили \n$cancelResponse = $client-\u003ecancelInvoice('', $senderCode); // отмена с собственным id заказа\n\n```\nИнформация об отправлении \n\n```\n$response = $client-\u003eshipmentInfo($invoiceNumber);\n$response = $client-\u003eshipmentInfo('', $senderCode);\n```\nВызов курьера\n\n```\n$senderDestination = new SenderDestination('Москва', 'Московская обл.', '', 992); \n\n$courierCall = new CourierCall(\n    $senderDestination-\u003egetCity(),\n    $senderDestination-\u003egetCityId(),\n    $senderDestination-\u003egetAddress(),\n   'Тестов Тест',\n    '+79274269594',\n    new \\DateTime('tomorrow + 1 day'),\n    12 * 60, // from 12:00,\n    17 * 60, // to 17:00\n    1, // 1 заказ,\n    1, // 10 кг\n    'Это тестовый вызов, пожалуйста не приезжайте'\n );\n\n$callCourier = $client-\u003ecallCourier($courierCall);\n$courierOrderNumber = $callCourier-\u003egetCallOrderNumber();\n```\nОтмена вызова курьера\n```\n\n$cancelResponse = $client-\u003ecancelCourierCall($courierOrderNumber);\n\n```\n\nИстория изменения отправления \n```\n$response = $client-\u003egetInvoicesTrackHistory([$invoiceNumber]);\n\n$states = $client-\u003egetInvoiceStatesTrackHistory($invoiceNumber);\n\n$lastSates = $client-\u003egetInvoicesLastStates([$invoiceNumber]);\n\n```\n\nОбновление полей отправления\n```\n$updateInvoice-\u003esetInvoiceNumber($invoice-\u003egetInvoiceNumber());\n$updateInvoice-\u003esetRecipientName(\"Кек чебурек\");\n$updateInvoice-\u003esetSum(20.32);\n$updateInvoice-\u003esetMobilePhone('+745642411');\n$response = $client-\u003eupdateShipment($updateInvoice);\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsch-group%2Fpickpoint-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsch-group%2Fpickpoint-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsch-group%2Fpickpoint-sdk/lists"}