简体   繁体   English

UPS API PHP - 终点URL

[英]UPS API PHP - End point URL

I have downloaded a PHP SDK for the UPS API. 我已经为UPS API下载了一个PHP SDK。 I have the following code and have no idea what an end point URL is. 我有以下代码,不知道端点URL是什么。 The documentation does not provide any information on what this is. 该文档未提供有关此内容的任何信息。

  //Configuration
  $access = "0C81234564C2567";
  $userid = "leannetest";
  $passwd = "456hththd8hf";

  $accessSchemaFile = "schemas/AccessRequest.xsd";
  $requestSchemaFile = "schemas/RateRequest.xsd";
  $responseSchemaFile = "schemas/RateResponse.xsd";

  $endpointurl = 'add URL here';
  $outputFileName = "XOLTResult.xml";

Can anyone help? 有人可以帮忙吗?

An API endpoint "defines the address or connection point to a Web service. It is typically represented by a simple HTTP URL string". API端点“定义Web服务的地址或连接点。它通常由简单的HTTP URL字符串表示”。 So basically, the endpoint URL is the URL of the web service that are you attempting to interact with. 基本上,端点URL是您尝试与之交互的Web服务的URL。

SOURCE: 资源:

http://en.wikipedia.org/wiki/Web_Services_Description_Language#Objects_in_WSDL_1.1_.2F_WSDL_2.0 http://en.wikipedia.org/wiki/Web_Services_Description_Language#Objects_in_WSDL_1.1_.2F_WSDL_2.0

EDIT: It appears from the documentation that the Rate webservices endpoint URL is https://wwwcie.ups.com/webservices/Rate . 编辑:从文档中可以看出, Rate webservices端点URL是https://wwwcie.ups.com/webservices/Rate

SOURCE: 资源:

UPS. UPS。 (January 2, 2002). (2002年1月2日)。 Rating Package Web Services Developers Guide . 评级包Web服务开发人员指南 Section 1.9.3 Server Availability Check . 第1.9.3节服务器可用性检查 Accessed in Rating API found on this page: https://www.ups.com/upsdeveloperkit/downloadresource?loc=en_US 访问此页面上的评级API: https//www.ups.com/upsdeveloperkit/downloadresource?loc = en_US

Endpoint url explaination in the UPS document. UPS文件中的端点URL说明。 it consists of four parts which are explained below. 它由四部分组成,如下所述。

For example if we are going to use "Rate" service than our urls should be as below. 例如,如果我们要使用“费率”服务,那么我们的网址应如下所示。


As per the documentation if we devide the url in four parts all of them are as listed below. 根据文档,如果我们将URL分为四个部分,则所有部分如下所示。

Protocol : https 协议: https
Name of server : wwwcie.ups.com (testing) OR onlinetools.ups.com (production) 服务器名称: wwwcie.ups.com(测试) onlinetools.ups.com(生产)
Path of service : ups.app/xml/Rate 服务路径: ups.app/xml/Rate
name of the service : Rate OR Ship OR QVEvents 服务名称 :费率发货 QVEvents

I just replied to explain UPS endpoint url in detail so it might help 我只是回复详细解释UPS端点URL,这可能有所帮助

The shipping endpoint url is: 发货端点网址为:

https://wwwcie.ups.com/webservices/Ship https://wwwcie.ups.com/webservices/Ship

In case anyone needs it, since it's not documented in their developers kit. 如果有人需要它,因为它没有记录在他们的开发人员工具包中。

Indeed the documentation is poor but with a little google trick I got the list of all the endpoint URLs 事实上,文档很差,但有一点google技巧,我得到了所有端点URL的列表

Type in google search: 输入谷歌搜索:

site: https://onlinetools.ups.com/ups.app/xml/ 网站: https//onlinetools.ups.com/ups.app/xml/

In this way, it will show you all the endpoints. 通过这种方式,它将显示所有端点。

Note: Do not use the sandbox URLs because they don't work at all :( 注意:请勿使用沙盒网址,因为它们根本不起作用:(

Anyway, here is the list: 无论如何,这是列表:

https://onlinetools.ups.com/ups.app/xml/TimeInTransit https://onlinetools.ups.com/ups.app/xml/TimeInTransit

https://onlinetools.ups.com/ups.app/xml/License https://onlinetools.ups.com/ups.app/xml/License

https://onlinetools.ups.com/ups.app/xml/QVEvents https://onlinetools.ups.com/ups.app/xml/QVEvents

https://onlinetools.ups.com/ups.app/xml/Register https://onlinetools.ups.com/ups.app/xml/Register

https://onlinetools.ups.com/ups.app/xml/AV https://onlinetools.ups.com/ups.app/xml/AV

https://onlinetools.ups.com/ups.app/xml/ShipAccept https://onlinetools.ups.com/ups.app/xml/ShipAccept

https://onlinetools.ups.com/ups.app/xml/Void https://onlinetools.ups.com/ups.app/xml/Void

https://onlinetools.ups.com/ups.app/xml/XAV https://onlinetools.ups.com/ups.app/xml/XAV

https://onlinetools.ups.com/ups.app/xml/Track https://onlinetools.ups.com/ups.app/xml/Track

https://onlinetools.ups.com/ups.app/xml/Rate https://onlinetools.ups.com/ups.app/xml/Rate

https://onlinetools.ups.com/ups.app/xml/ShipConfirm https://onlinetools.ups.com/ups.app/xml/ShipConfirm

https://onlinetools.ups.com/ups.app/xml/LabelRecovery https://onlinetools.ups.com/ups.app/xml/LabelRecovery

I hope this help 我希望这有帮助

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM