API: List Projects

Lists all Projects in the account.

Note: Before using this call, you'll need to authenticate against the API as detailed in Making your first call to the Project API.

 

Note: This endpoint has been improved. The previous method of searching is still supported and if you are using that, then there is no need to make a change unless you wish to take advantage of the new functionality.

 

It's possible to search for Projects by specifying logic and operands as well as pure values.

The anatomy of the search is made up of the following components:

{logic}-{key}-{operand}-{type}-{value}

 

These components can be described as follows:

 

logic -  Decides whether to apply "AND"  or "OR".

key - the field to which the search criterion is applied. Please note than when searching for a release, you still need to include the Project code the releases belong to as a key-value pair.

operand - specifies how Projects should be compared to the criterion to determine whether they are returned as results or not.

type - specified whether to use value of a given field (described by the key) for comparison, or another field.

value - Either a specific value, or the name of the field to compare.

 

Some examples of this in use are:

 

and-name-ne-value-foo

Returns all projects that name is NOT equal to foo
and-name-inc-value-foo

Returns all projects where the name is LIKE foo (case sensitive)
and-name-inci-value-foo

Returns all projects where the name is LIKE foo (case insensitive)
or-tag_name-eq-value-red|or-tag_name-eq-value-blue

Returns all projects that are tagged red or blue
and-name-eq-value-foo|and-tag_name-ini-value-red,blue

Returns all projects where the name is equal to foo & associated tags are red and blue
and-project_code-eq-value-abc|and-status-eq-value-complete

Returns all complete releases for a given project code

Options for Logic:

AND - specifies that result should be included where all criteria are met
OR - specifies that result should be included if it matches at least one of the criteria

Options for Operands:

bool - Boolean comparison, e.g. true or false (is NULL | is not NULL). eq - Equals comparison (case sensitive).
eqi - Equals comparison (case insensitive).
ne - Not equals comparison (case sensitive). 
nei - Not equals comparison (case insensitive). lt - Less than comparison.
gt - Greater than comparison.
ge - Greater than or equal to comparison. 
le - Less than or equal to comparison. inc - Includes (case sensitive).
inci - Includes (case insensitive).
ninc - Not includes (case sensitive). ninci - Not includes (case insensitive). re - Regular expression. 
begins - Begins (case sensitive).
beginsi - Begins (case insensitive).
in - Comma delimited list of values to match (case sensitive).
ini - Comma delimited list of values to match (case insensitive).
nin - Comma delimited list of values to not match (case sensitive).
nini - Comma delimited list of values to not match (case insensitive). 

 

Possible Project Level Search Fields:

 name
 project_code
 created
 deleted
 project_views
 project_views_this_month
 project_passes
 project_fails
 theme_skin_id
 name_in_release
 language
 theme
 theme_version_number
 scorm_mode
 lrs_endpoint
 lrs_endpoint_username
 learner_access
 project_description
 use_learner_service
 last_destructive_change
 tag_name
 tag_color

 

Possible Release Level Search Fields:

release_code
created
modified
status
description
release_views
release_views_this_month
release_passes
release_fails
release_last_view
version_number
release_mode
download_url
cdn_path
lrs_endpoint
lrs_endpoint_username
learner_access
release_type
master_release_id
send_email_to_id
release_key_expiry
release_key
video_encoding_quality
use_bookmark_service
cdn_url_path_params
homepage_url
css_url
js_url
version_number_minor
with_secure_cdn
release_finished

Code examples are included below. All of these examples have simulation mode turned on. Once you are read to use in a production environment, you can remove the simulation parameter. Any changes will then affect your account.

The full example search string, even when it contains a pipe, should be included as the argument against the "search" field.

When searching for releases, you'll need to use https://api.elucidat.com/v2/releases as the endpoint, and provide a Project code as the first argument.

 

PHP

Python

Response

 

PHP

$nonce = get_nonce('https://api.elucidat.com/v2/projects', 'PUBLIC_KEY', 'PRIVATE_KEY');
$headers = auth_headers('PUBLIC_KEY', $nonce);
$fields = array(
    'simulation_mode' => 'simulation',
    'search' => $arg1,
    'order' => $arg2
);
$result = call_elucidat($headers, $fields, 'GET', 'https://api.elucidat.com/v2/projects', 'PRIVATE_KEY');
echo ("HTTP status code: " . $result['status'] . "\n");
print_r($result['response']);

Python 3.9

     endpoint = '/v2/projects'
method = 'GET'
params = {'search': 'and-name-inc-value-foo',
'simulation_mode': 'simulation'}
data = {}
api = Api(api_root, endpoint, method, params, data, private_key, public_key)
api.call_elucidat()

Response

[
{
"project_code": "60b64d4492fa6",
"name": "Audio Test",
"created": "2021-06-01 15:07:48",
"project_views": "0",
"project_views_this_month": "0",
"project_passes": "0",
"project_fails": "0",
"theme_skin_id": "27895",
"name_in_release": "",
"language": "en-GB",
"theme": "master_theme",
"theme_version_number": "1",
"scorm_mode": "1.2",
"lrs_endpoint": null,
"lrs_endpoint_username": null,
"learner_access": "any",
"project_description": null,
"use_learner_service": "0",
"edit_url": "https://app.elucidat.com/projects/edit/60b64d4492fa6",
"type": "project"
}
]
Was this article helpful?
0 out of 0 found this helpful

Articles in this section

See more
Request support
Access support that’s tailored to you by getting in touch with our Support Team.
Send us feedback
Do you have a new feature request, or want to tell us about something that works well (or not so well) for you? Get in touch!