Create a Project
Projects encapsulate an entire campaign including Assets, QR Codes and Scans. Think of a Project as a folder to organize your resources.
Requirements
A (free) Openscreen account
Locally installed Openscreen SDK
Authenticated with Openscreen SDK
Create an Openscreen Project
Paste the following code after you have initiated a session with the Openscreen SDK:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Obtain your accountId from the Openscreen Dashboard
const accountId = "XXXXXXXXXXXXXXXXXX";
async function main() {
//Create a Project
const projectRes = await os.account(accountId).projects().create({
"name": "OS Engage Campaign",
"description": "QR code initated customer engagement campaign",
});
}
main().catch(err => {
console.log(JSON.stringify(err, ' ', 2))
});
1
2
3
4
5
6
7
#Obtain your account_id from the Openscreen Dashboard
account_id = "XXXXXXXXXXXXXXXXXX"
project_res = os.account(account_id).projects().create({
"name": 'Real Estate Listings",
"description": "Connect new and existing clients to listings"
})
The response object from this call will contain a unique projectId. You will need this projectId to create other Openscreen resources. Use the code below to retrieve this projectId:
1
const { projectId } = projectRes.project;
1
project_id = project_res.project.project_id