curl --request GET \
--url https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName} \
--header 'Authorization: Bearer <token>'import requests
url = "https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"name": "<string>",
"latestVersion": "<string>",
"description": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"replicationCount": 5,
"resourceIdentifier": "<string>",
"indexStatus": "unknown",
"autoPromote": true,
"autoArchiveTtl": "<string>"
}{
"code": "<string>",
"message": "<string>"
}{
"code": "<string>",
"message": "<string>"
}{
"code": "<string>",
"message": "<string>"
}{
"code": "<string>",
"message": "<string>"
}Get package details
Retrieves detailed information about a specific package including metadata, version information, and configuration details.
Authorization: Requires read access to the package.
Parameters: The checkAdmin parameter can be used to verify admin privileges.
curl --request GET \
--url https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName} \
--header 'Authorization: Bearer <token>'import requests
url = "https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{organization}.admin.credibledata.com/api/v0/organizations/{organizationName}/environments/{environmentName}/packages/{packageName}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"name": "<string>",
"latestVersion": "<string>",
"description": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"replicationCount": 5,
"resourceIdentifier": "<string>",
"indexStatus": "unknown",
"autoPromote": true,
"autoArchiveTtl": "<string>"
}{
"code": "<string>",
"message": "<string>"
}{
"code": "<string>",
"message": "<string>"
}{
"code": "<string>",
"message": "<string>"
}{
"code": "<string>",
"message": "<string>"
}Authorizations
Path Parameters
Response
Package details retrieved successfully
Represents a Malloy data model package containing models, queries, and related resources
Status of the indexing process. Possible values: unknown (initial state, indexing not yet started), indexing (currently being processed), indexed (successfully indexed and ready for use), failed (indexing process encountered an error).
unknown, indexing, indexed, failed, retry Package-scoped auto-promote policy applied as a default to each newly
published version: when true, a new version is armed (see
Version.promoteWhenReady) and the lifecycle reconciler promotes it to
latestVersion once it is ready, subject to the never-been-latest
rollback guard. Newly created packages default this to true: a package
created without an explicit autoPromote gets auto-promote enabled.
Omitting the field on update leaves the policy unchanged; toggling it on
does not retroactively arm existing versions. Independent of
autoArchiveTtl.
Package-scoped ttl auto-archive policy: how long a version is retained
after it stops being latest, e.g. 30d, 24h, 2w (units s, m, h, d,
w). A formerly-latest version is archived (its materialized tables
reclaimed) once it has been demoted for longer than this ttl; the current
latest is never archived. 0 archives a version as soon as it is demoted
(keep-only-latest, modulo the reconciler tick) — note this trades away the
cheap rollback window. A non-empty value enables auto-archive; an empty
string disables it. Newly created packages default to 30d: a package
created without an explicit autoArchiveTtl gets 30-day auto-archive.
Omitting the field on update leaves the policy unchanged. Independent of
autoPromote.
Was this page helpful?