# README
Go API client for openapi
Welcome to the Pingdom API!
The Pingdom API is a way for you to automate your interaction with the Pingdom system. With the API, you can create your own scripts or applications with most of the functionality you can find inside the Pingdom control panel.
The Pingdom API is RESTful and HTTP-based. Basically, this means that the communication is made through normal HTTP requests.
Authentication
Authentication is needed in order to use the Pingdom API, and for this a Pingdom API Token is required. You generate your Pingdom API Token inside My Pingdom. The Pingdom API Token has a property called “Access level” to define its permissions. All operations that create or modify something (e.g. checks) need the Read/Write permission. If you only need to read data using the API token, we recommend to set the access level to “Read access”.
The authentication method for using tokens is HTTP Bearer Authentication (encrypted over HTTPS). This means that you will provide your token every time you make a request. No sessions are used.
Request
GET /checks HTTP/1.1
Host: api.pingdom.com
Authorization: Bearer ofOhK18Ca6w4S_XmInGv0QPkqly-rbRBBoHsp_2FEH5QnIbH0VZhRPO3tlvrjMIKQ36VapX
Response
HTTP/1.1 200 OK
Content-Length: 13
Content-Type: application/json
{\"checks\":[]}
Basic Auth
For compatibility reasons, the Pingdom API allows to use HTTP Basic Authentication with tokens. In cases where this is necessary, input the API token as the username and leave the password field empty.
An example request of how that would look like with the following API token: ofOhK18Ca6w4S_XmInGv0QPkqly-rbRBBoHsp_2FEH5QnIbH0VZhRPO3tlvrjMIKQ36VapX
GET /checks HTTP/1.1
Host: api.pingdom.com
Authorization: Basic b2ZPaEsxOENhNnc0U19YbUluR3YwUVBrcWx5LXJiUkJCb0hzcF8yRkVINVFuSWJIMFZaaFJQTzN0bHZyak1JS1EzNlZhcFg6
Server Address
The base server address is: https://api.pingdom.com
Please note that HTTPS is required. You will not be able to connect through unencrypted HTTP.
Providing Parameters
GET requests should provide their parameters as a query string, part of the URL.
POST, PUT and DELETE requests should provide their parameters as a JSON. This should be part of the request body. Remember to add the proper content type header to the request: Content-Type: application/json
.
We still support providing parameters as a query string for POST, PUT and DELETE requests, but we recommend using JSON going forward. If you are using query strings, they should be part of the body, URL or a combination. The encoding of the query string should be standard URL-encoding, as provided by various programming libraries.
When using requests
library for Python, use json
parameter instead of data
. Due to the inner mechanisms of requests.post() etc. some endpoints may return responses not conforming to the documentation when dealing with data
body.
HTTP/1.1 Status Code Definitions
The HTTP status code returned by a successful API request is defined in the documentation for that method. Usually, this will be 200 OK.
If something goes wrong, other codes may be returned. The API uses standard HTTP/1.1 status codes defined by RFC 2616.
JSON Responses
All responses are sent JSON-encoded. The specific responses (successful ones) are described in the documentation section for each method.
However, if something goes wrong, our standard JSON error message (together with an appropriate status code) follows this format:
{
\"error\": {
\"statuscode\": 403,
\"statusdesc\": \"Forbidden\",
\"errormessage\":\" Something went wrong! This string describes what happened.\"
}
}
See http://en.wikipedia.org/wiki/Json for more information on JSON.
Please note that all attributes of a method response are not always present. A client application should never assume that a certain attribute is present in a response.
Limits
The Pingdom API has usage limits to avoid individual rampant applications degrading the overall user experience. There are two layers of limits, the first cover a shorter period of time and the second a longer period. This enables you to "burst" requests for shorter periods. There are two HTTP headers in every response describing your limits status.
The response headers are:
- Req-Limit-Short
- Req-Limit-Long
An example of the values of these headers:
- Req-Limit-Short: Remaining: 394 Time until reset: 3589
- Req-Limit-Long: Remaining: 71994 Time until reset: 2591989
In this case, we can see that the user has 394 requests left until the short limit is reached. In 3589 seconds, the short limit will be reset. In similar fashion, the long limit has 71994 requests left, and will be reset in 2591989 seconds.
If limits are exceeded, an HTTP 429 error code with the message "Request limit exceeded, try again later" is sent back.
gzip
Responses can be gzip-encoded on demand. This is nice if your bandwidth is limited, or if big results are causing performance issues.
To enable gzip, simply add the following header to your request:
Accept-Encoding: gzip
Best Practices
Use caching
If you are building a web page using the Pingdom API, we recommend that you do all API request on the server side, and if possible cache them. If you get any substantial traffic, you do not want to call the API each time you get a page hit, since this may cause you to hit the request limit faster than expected. In general, whenever you can cache data, do so.
Send your user credentials in a preemptive manner
Some HTTP clients omit the authentication header, and make a second request with the header when they get a 401 Unauthorized response. Please make sure you send the credentials directly, to avoid unnecessary requests.
Use common sense
Should be simple enough. For example, don't check for the status of a check every other second. The highest check resolution is one minute. Checking more often than that won't give you much of an advantage.
The Internet is unreliable
Networks in general are unreliable, and particularly one as large and complex as the Internet. Your application should not assume it will get an answer. There may be timeouts.
PHP Code Example
"This is too much to read. I just want to get started right now! Give me a simple example!"
Here is a short example of how you can use the API with PHP. You need the cURL extension for PHP.
The example prints the current status of all your checks. This sample obviously focuses on Pingdom API code and does not worry about any potential problems connecting to the API, but your code should.
Code:
<?php
// Init cURL
$curl = curl_init();
// Set target URL
curl_setopt($curl, CURLOPT_URL, \"https://api.pingdom.com/api/3.1/checks\");
// Set the desired HTTP method (GET is default, see the documentation for each request)
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, \"GET\");
// Add header with Bearer Authorization
curl_setopt($curl, CURLOPT_HTTPHEADER, array(\"Authorization: Bearer 907c762e069589c2cd2a229cdae7b8778caa9f07\"));
// Ask cURL to return the result as a string
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
// Execute the request and decode the json result into an associative array
$response = json_decode(curl_exec($curl), true);
// Check for errors returned by the API
if (isset($response['error'])) {
print \"Error: \" . $response['error']['errormessage'] . \"\\n\";
exit;
}
// Fetch the list of checks from the response
$checksList = $response['checks'];
// Print the names and statuses of all checks in the list
foreach ($checksList as $check) {
print $check['name'] . \" is \" . $check['status'] . \"\\n\";
}
?>
Example output:
Ubuntu Packages is up
Google is up
Pingdom is up
My server 1 is down
My server 2 is up
If you are running PHP on Windows, you need to be sure that you have installed the CA certificates for HTTPS/SSL to work correctly. Please see the cURL manual for more information. As a quick (but unsafe) workaround, you can add the following cURL option to ignore certificate validation.
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, 0);
TMS Steps Vocabulary
There are two types of transaction checks:
- script: the legacy TMS check created with predefined commands in the Pingdom UI or via the public API
- recording: the TMS check created by recording performed actions in WPM recorder. More information about how to use it can be found in the WPM recorder documentation
Script transaction checks
Commands
Actions to be performed for the script TMS check
Step Name | "fn" | Required "args" | Remarks |
---|---|---|---|
Go to URL | go_to | url | There has to be exactly one go_to step |
Click | click | element | label, name or CSS selector |
Fill in field | fill | input, value | input: label, name or CSS selector, value: text |
Check checkbox | check | checkbox | label, name or CSS selector |
Uncheck checkbox | uncheck | checkbox | label, name or CSS selector |
Sleep for | sleep | seconds | number (e.g. 0.1) |
Select radio button | select_radio | radio | name of the radio button |
Select dropdown | select | select, option | select: label, name or CSS selector, option: content, value or CSS selector |
Basic auth login with | basic_auth | username, password | username and password as text |
Submit form | submit | form | name or CSS selector |
Wait for element | wait_for_element | element | label, name or CSS selector |
Wait for element to contain | wait_for_contains | element, value | element: label, name or CSS selector, value: text |
Validations
Verify the state of the page
Step Name | "fn" | Required "args" | Remarks |
---|---|---|---|
URL should be | url | url | url to be verified |
Element should exist | exists | element | label, name or CSS selector |
Element shouldn't exist | not_exists | element | label, name or CSS selector |
Element should contain | contains | element, value | element: label, name or CSS selector, value: text |
Element shouldn't containt | not_contains | element, value | element: label, name or CSS selector, value: text |
Text field should contain | field_contains | input, value | input: label, name or CSS selector, value: text |
Text field shouldn't contain | field_not_contains | input, value | input: label, name or CSS selector, value: text |
Checkbox should be checked | is_checked | checkbox | label, name or CSS selector |
Checkbox shouldn't be checked | is_not_checked | checkbox | label, name or CSS selector |
Radio button should be selected | radio_selected | radio | name of the radio button |
Dropdown with name should be selected | dropdown_selected | select, option | select: label, name or CSS selector, option: content, value or CSS selector |
Dropdown with name shouldn't be selected | dropdown_not_selected | select, option | select: label, name or CSS selector, option: content, value or CSS selector |
Example steps
\"steps\": [
{
\"fn\": \"go_to\",
\"args\": {
\"url\": \"pingdom.com\"
}
},
{
\"fn\": \"click\",
\"args\": {
\"element\": \"START FREE TRIAL\"
}
},
{
\"fn\": \"url\",
\"args\": {
\"url\": \"https://www.pingdom.com/sign-up/\"
}
}
]
Recording transaction checks
Each of check steps contains:
- fn: function name of the step
- args: function arguments
- guid: automatically generated identifier
- contains_navigate: recorder sets it on true if the step would trigger a page navigation
Commands
Actions to be performed for the recording TMS check
Step Name | "fn" | Required "args" | Remarks |
---|---|---|---|
Go to URL | wpm_go_to | url | Goes to the given url location |
Click | wpm_click | element, offsetX, offsetY | element: label, name or CSS selector, offsetX/Y: exact position of a click in the element |
Click in a exact location | wpm_click_xy | element, x, y, scrollX, scrollY | element: label, name or CSS selector, x/y: coordinates for the click (in viewport), scrollX/Y: scrollbar position |
Fill | wpm_fill | input, value | input: target element, value: text to fill the target |
Move mouse to element | wpm_move_mouse_to_element | element, offsetX, offsetY | element: target element, offsetX/Y: exact position of the mouse in the element |
Select dropdown | wpm_select_dropdown | select, option | select: target element (drop-down), option: text of the option to select |
Wait | wpm_wait | seconds | seconds: numbers of seconds to wait |
Close tab | wpm_close_tab | - | Closes the latest tab on the tab stack |
Validations
Verify the state of the page
Step Name | "fn" | Required "args" | Remarks |
---|---|---|---|
Contains text | wpm_contains_timeout | element, value, waitTime, useRegularExpression | element: label, name or CSS selector, value: text to search for, waitTime: time to wait for the value to appear, useRegularExpression: use the value as a RegEx |
Does not contains text | wpm_not_contains_timeout | element, value, waitTime, useRegularExpression | element: label, name or CSS selector, value: text to search for, waitTime: time to wait for the value to appear, useRegularExpression: use the value as a RegEx |
Metadata
Recording checks contain metadata which is automatically generated by the WPM recorder. Modify with caution!
Overview
This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.
- API version: 3.1
- Package version: 1.0.0
- Build package: org.openapitools.codegen.languages.GoClientCodegen
Installation
Install the following dependencies:
go get github.com/stretchr/testify/assert
go get golang.org/x/net/context
Put the package under your project folder and add the following in import:
import openapi "github.com/karlderkaefer/pingdom-golang-client/pkg/pingdom/openapi"
To use a proxy, set the environment variable HTTP_PROXY
:
os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")
Configuration of Server URL
Default configuration comes with Servers
field that contains server objects as defined in the OpenAPI specification.
Select Server Configuration
For using other server than the one defined on index 0 set context value openapi.ContextServerIndex
of type int
.
ctx := context.WithValue(context.Background(), openapi.ContextServerIndex, 1)
Templated Server URL
Templated server URL is formatted using default variables from configuration or from context value openapi.ContextServerVariables
of type map[string]string
.
ctx := context.WithValue(context.Background(), openapi.ContextServerVariables, map[string]string{
"basePath": "v2",
})
Note, enum values are always validated and all unused variables are silently ignored.
URLs Configuration per Operation
Each operation can use different server URL defined using OperationServers
map in the Configuration
.
An operation is uniquely identified by "{classname}Service.{nickname}"
string.
Similar rules for overriding default operation server index and variables applies by using openapi.ContextOperationServerIndices
and openapi.ContextOperationServerVariables
context maps.
ctx := context.WithValue(context.Background(), openapi.ContextOperationServerIndices, map[string]int{
"{classname}Service.{nickname}": 2,
})
ctx = context.WithValue(context.Background(), openapi.ContextOperationServerVariables, map[string]map[string]string{
"{classname}Service.{nickname}": {
"port": "8443",
},
})
Documentation for API Endpoints
All URIs are relative to https://api.pingdom.com/api/3.1
Class | Method | HTTP request | Description |
---|---|---|---|
ActionsAPI | ActionsGet | Get /actions | Returns a list of actions alerts. |
AnalysisAPI | AnalysisCheckidAnalysisidGet | Get /analysis/{checkid}/{analysisid} | Returns the raw result for a specified analysis. |
AnalysisAPI | AnalysisCheckidGet | Get /analysis/{checkid} | Returns a list of the latest root cause analysis |
ChecksAPI | ChecksCheckidDelete | Delete /checks/{checkid} | Deletes a check. |
ChecksAPI | ChecksCheckidGet | Get /checks/{checkid} | Returns a detailed description of a check. |
ChecksAPI | ChecksCheckidPut | Put /checks/{checkid} | Modify settings for a check. |
ChecksAPI | ChecksDelete | Delete /checks | Deletes a list of checks. |
ChecksAPI | ChecksGet | Get /checks | |
ChecksAPI | ChecksPost | Post /checks | Creates a new check. |
ChecksAPI | ChecksPut | Put /checks | Pause or change resolution for multiple checks. |
ContactsAPI | AlertingContactsContactidDelete | Delete /alerting/contacts/{contactid} | Deletes a contact with its contact methods |
ContactsAPI | AlertingContactsContactidGet | Get /alerting/contacts/{contactid} | Returns a contact with its contact methods |
ContactsAPI | AlertingContactsContactidPut | Put /alerting/contacts/{contactid} | Update a contact |
ContactsAPI | AlertingContactsGet | Get /alerting/contacts | Returns a list of all contacts |
ContactsAPI | AlertingContactsPost | Post /alerting/contacts | Creates a new contact |
CreditsAPI | CreditsGet | Get /credits | Returns information about remaining credits |
MaintenanceAPI | MaintenanceDelete | Delete /maintenance | Delete multiple maintenance windows. |
MaintenanceAPI | MaintenanceGet | Get /maintenance | |
MaintenanceAPI | MaintenanceIdDelete | Delete /maintenance/{id} | Delete the maintenance window. |
MaintenanceAPI | MaintenanceIdGet | Get /maintenance/{id} | |
MaintenanceAPI | MaintenanceIdPut | Put /maintenance/{id} | |
MaintenanceAPI | MaintenancePost | Post /maintenance | |
MaintenanceOccurrencesAPI | MaintenanceOccurrencesDelete | Delete /maintenance.occurrences | Deletes multiple maintenance occurrences |
MaintenanceOccurrencesAPI | MaintenanceOccurrencesGet | Get /maintenance.occurrences | Returns a list of maintenance occurrences. |
MaintenanceOccurrencesAPI | MaintenanceOccurrencesIdDelete | Delete /maintenance.occurrences/{id} | Deletes the maintenance occurrence |
MaintenanceOccurrencesAPI | MaintenanceOccurrencesIdGet | Get /maintenance.occurrences/{id} | Gets a maintenance occurrence details |
MaintenanceOccurrencesAPI | MaintenanceOccurrencesIdPut | Put /maintenance.occurrences/{id} | Modifies a maintenance occurrence |
ProbesAPI | ProbesGet | Get /probes | Returns a list of Pingdom probe servers |
ReferenceAPI | ReferenceGet | Get /reference | Get regions, timezone and date/time/number references |
ResultsAPI | ResultsCheckidGet | Get /results/{checkid} | Return a list of raw test results |
SingleAPI | SingleGet | Get /single | Performs a single check. |
SummaryAverageAPI | SummaryAverageCheckidGet | Get /summary.average/{checkid} | Get the average time/uptime value for a specified |
SummaryHoursofdayAPI | SummaryHoursofdayCheckidGet | Get /summary.hoursofday/{checkid} | Returns the average response time for each hour. |
SummaryOutageAPI | SummaryOutageCheckidGet | Get /summary.outage/{checkid} | Get a list of status changes for a specified check |
SummaryPerformanceAPI | SummaryPerformanceCheckidGet | Get /summary.performance/{checkid} | For a given interval return a list of subintervals |
SummaryProbesAPI | SummaryProbesCheckidGet | Get /summary.probes/{checkid} | Get a list of probes that performed tests |
TMSChecksAPI | AddCheck | Post /tms/check | Creates a new transaction check. |
TMSChecksAPI | DeleteCheck | Delete /tms/check/{cid} | Deletes a transaction check. |
TMSChecksAPI | GetAllChecks | Get /tms/check | Returns a list overview of all transaction checks. |
TMSChecksAPI | GetCheck | Get /tms/check/{cid} | Returns a single transaction check. |
TMSChecksAPI | GetCheckReportPerformance | Get /tms/check/{check_id}/report/performance | Returns a performance report for a single transaction check |
TMSChecksAPI | GetCheckReportStatus | Get /tms/check/{check_id}/report/status | Returns a status change report for a single transaction check |
TMSChecksAPI | GetCheckReportStatusAll | Get /tms/check/report/status | Returns a status change report for all transaction checks in the current organization |
TMSChecksAPI | ModifyCheck | Put /tms/check/{cid} | Modify settings for transaction check. |
TeamsAPI | AlertingTeamsGet | Get /alerting/teams | |
TeamsAPI | AlertingTeamsPost | Post /alerting/teams | Creates a new team |
TeamsAPI | AlertingTeamsTeamidDelete | Delete /alerting/teams/{teamid} | |
TeamsAPI | AlertingTeamsTeamidGet | Get /alerting/teams/{teamid} | |
TeamsAPI | AlertingTeamsTeamidPut | Put /alerting/teams/{teamid} | |
TracerouteAPI | TracerouteGet | Get /traceroute | Perform a traceroute |
Documentation For Models
- AGCMInner
- APNSInner
- ActionsAlertsEntry
- ActionsAlertsEntryActions
- ActionsAlertsEntryActionsAlertsInner
- AlertingContactsContactidDelete200Response
- AlertingContactsPost200Response
- AlertingContactsPost200ResponseContact
- AlertingTeamID
- AlertingTeams
- AlertingTeamsPost200Response
- AlertingTeamsPost200ResponseTeam
- AlertingTeamsTeamidDelete200Response
- AnalysisRespAttrs
- AnalysisRespAttrsAnalysisInner
- Check
- CheckGeneral
- CheckSimple
- CheckStatus
- CheckWithStringType
- CheckWithoutID
- CheckWithoutIDGET
- CheckWithoutIDPUT
- Checks
- ChecksAll
- ChecksCheckidDelete200Response
- ChecksCheckidPut200Response
- ChecksDelete200Response
- ChecksPost200Response
- ChecksPost200ResponseCheck
- ChecksPut200Response
- ChecksPutRequest
- Contact
- ContactTargets
- ContactTargetsNotificationTargets
- ContactTargetsTeamsInner
- ContactsList
- Country
- Counts
- CreateCheck
- CreateContact
- CreateContactNotificationTargets
- CreateTeam
- CreditsRespAttrs
- CreditsRespAttrsCredits
- DNS
- DateTimeFormat
- Days
- DeleteCheck200Response
- DetailedCheck
- DetailedCheckAttributes
- DetailedCheckDns
- DetailedCheckDnsCheck
- DetailedCheckHttp
- DetailedCheckHttpCheck
- DetailedCheckHttpCustom
- DetailedCheckHttpCustomCheck
- DetailedCheckImap
- DetailedCheckImapCheck
- DetailedCheckPop3
- DetailedCheckPop3Check
- DetailedCheckSmtp
- DetailedCheckSmtpCheck
- DetailedCheckTcp
- DetailedCheckTcpCheck
- DetailedCheckUdp
- DetailedCheckUdpCheck
- DetailedDnsAttributes
- DetailedDnsAttributesType
- DetailedHttpAttributes
- DetailedHttpAttributesType
- DetailedHttpCustomAttributes
- DetailedHttpCustomAttributesType
- DetailedImapAttributes
- DetailedImapAttributesType
- DetailedPop3Attributes
- DetailedPop3AttributesType
- DetailedSmtpAttributes
- DetailedSmtpAttributesType
- DetailedTcpAttributes
- DetailedTcpAttributesType
- DetailedUdpAttributes
- DetailedUdpAttributesType
- DnsAttributes
- EmailsInner
- HTTP
- HTTPCustom
- Hours
- HttpAttributesBase
- HttpAttributesGet
- HttpAttributesSet
- HttpAuthentications
- HttpAuthenticationsCredentials
- HttpCertificateAttributes
- HttpCustomAttributes
- IMAP
- ImapAttributes
- MaintenanceDelete
- MaintenanceDeleteRespAttrs
- MaintenanceIdDeleteRespAttrs
- MaintenanceIdPut
- MaintenanceIdPutRespAttrs
- MaintenanceIdRespAttrs
- MaintenanceIdRespAttrsMaintenance
- MaintenanceIdRespAttrsMaintenanceChecks
- MaintenanceOccurrencesDelete
- MaintenanceOccurrencesDeleteRespAttrs
- MaintenanceOccurrencesIdDeleteRespAttrs
- MaintenanceOccurrencesIdPut
- MaintenanceOccurrencesIdPutRespAttrs
- MaintenanceOccurrencesIdRespAttrs
- MaintenanceOccurrencesIdRespAttrsOccurrence
- MaintenanceOccurrencesRespAttrs
- MaintenanceOccurrencesRespAttrsOccurrencesInner
- MaintenanceOrder
- MaintenanceOrderby
- MaintenancePost
- MaintenancePostRespAttrs
- MaintenancePostRespAttrsMaintenance
- MaintenanceRespAttrs
- MaintenanceRespAttrsMaintenanceInner
- MaintenanceRespAttrsMaintenanceInnerChecks
- Members
- Metadata
- MetadataGET
- MetadataGETAuthentications
- ModifyCheckSettings
- NumberFormat
- POP3
- PhoneCode
- Pop3Attributes
- Probe
- Probes
- References
- Region
- ReportPerformance
- ReportPerformanceReport
- ReportPerformanceReportIntervalsInner
- ReportPerformanceReportIntervalsInnerStepsInner
- ReportStatusAll
- ReportStatusSingle
- ResultsRespAttrs
- ResultsRespAttrsResultsInner
- SMSesInner
- SMTP
- SingleGetQueryParametersParameter
- SingleResp
- SingleRespResult
- SmtpAttributesBase
- SmtpAttributesGet
- SmtpAttributesSet
- State
- Step
- StepArgs
- SummaryHoursofdayRespAttrs
- SummaryHoursofdayRespAttrsHoursofdayInner
- SummaryOutageOrder
- SummaryOutageRespAttrs
- SummaryOutageRespAttrsSummary
- SummaryOutageRespAttrsSummaryStatesInner
- SummaryPerformanceOrder
- SummaryPerformanceResolution
- SummaryPerformanceRespAttrs
- SummaryPerformanceRespAttrsSummary
- SummaryPerformanceResultsInner
- SummaryProbesRespAttrs
- SummaryRespAttrs
- SummaryRespAttrsSummary
- SummaryRespAttrsSummaryResponsetime
- SummaryRespAttrsSummaryResponsetimeAvgresponse
- SummaryRespAttrsSummaryResponsetimeAvgresponseOneOfInner
- SummaryRespAttrsSummaryStatus
- TCP
- Tag
- TcpAttributes
- TeamID
- Teams
- Timezone
- Traceroute
- TracerouteData
- UDP
- UdpAttributes
- UpdateContact
- UpdateTeam
- Weeks
Documentation For Authorization
Endpoints do not require authorization.
Documentation for Utility Methods
Due to the fact that model structure members are all pointers, this package contains a number of utility functions to easily obtain pointers to values of basic types. Each of these functions takes a value of the given basic type and returns a pointer to it:
PtrBool
PtrInt
PtrInt32
PtrInt64
PtrFloat
PtrFloat32
PtrFloat64
PtrString
PtrTime