View connect_to_CRM.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// create contact in Openscreen | |
await os.project(process.env.OS_PROJECT_ID).contacts().create({ | |
firstName, | |
lastName, | |
emailAddress, | |
cellPhone, | |
consent, | |
}) | |
// add profile to list in Klaviyo |
View complete_klaviyo_integration.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('dotenv').config() | |
const express = require('express') | |
const path = require('path') | |
const bodyParser = require('body-parser') | |
const { Openscreen } = require('@openscreen/sdk') | |
// initialize Openscreen SDK | |
const os = new Openscreen().config({ | |
key: process.env.OS_API_KEY, | |
secret: process.env.OS_API_SECRET, |
View create_QR_code.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('dotenv').config() | |
const { Openscreen } = require('@openscreen/sdk') | |
// initialize Openscreen SDK | |
const os = new Openscreen().config({ | |
key: process.env.OS_API_KEY, | |
secret: process.env.OS_API_SECRET, | |
}) | |
// script that generates a QR code in the project's /public directory |
View getting_started_with_Openscreen_node_sdk.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Run the following code to test that you have successfully created a project and installed the Openscreen SDK. | |
// Initiate the Openscreen node SDK | |
const{ Openscreen }=require("@openscreen/sdk"); | |
require('dotenv').config(); | |
const os = new Openscreen().config({key: process.env.OS_API_KEY, secret: process.env.OS_API_SECRET}); | |
// Insert the project ID that you received using the Openscreen dashboard | |
const projectId ='xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'; | |
async function main(){ | |
View initiate_node_sdk.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { Openscreen } = require("@openscreen/sdk"); | |
require('dotenv').config(); | |
const os = new Openscreen().config({key: process.env.OS_API_KEY, secret: process.env.OS_API_SECRET}); | |
// Input the project ID that you received in the Openscreen dashboard as a string, your project ID should look similar to the one provided below | |
const projectId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'; |
View create_static_qr_code.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Initiate the Openscreen node SDK and include the project ID that you recieved using the Openscreen dashboard | |
const { Openscreen } = require("@openscreen/sdk"); | |
require('dotenv').config(); | |
const os = new Openscreen().config({key: process.env.OS_API_KEY, secret: process.env.OS_API_SECRET}); | |
const projectId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' | |
async function main() { | |
// Create an asset and generate a Static QR Code | |
const res = await os.project(projectId).assets().create({ |
View create_static_QR.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Initiate the Openscreen node SDK and include the project ID that you recieved using the Openscreen dashboard | |
const { Openscreen } = require("@openscreen/sdk"); | |
require('dotenv').config(); | |
const os = new Openscreen().config({key: process.env.OS_API_KEY, secret: process.env.OS_API_SECRET}); | |
const projectId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' | |
// Generate your first Static QR Code | |
async function main() { | |
// Create an asset and generate a static QR Code |
View create_dynamic_batch_qr.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Initiate the Openscreen node SDK and include the project ID that you recieved using the Openscreen dashboard | |
const { Openscreen } = require("@openscreen/sdk"); | |
require('dotenv').config(); | |
const os = new Openscreen().config({key: process.env.OS_API_KEY, secret: process.env.OS_API_SECRET}); | |
const projectId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'; | |
async function main(){ | |
// Create multiple assets that each represent a different billboard. Each of these billboards will direct a user to the same listing at 123 Cherry Street. |
View get_scan_info.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Initiate the Openscreen node SDK and include the project ID that you recieved using the Openscreen dashboard | |
const { Openscreen } = require("@openscreen/sdk"); | |
require('dotenv').config(); | |
const os = new Openscreen().config({key: process.env.OS_API_KEY, secret: process.env.OS_API_SECRET}); | |
const projectId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'; | |
const assetId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'; | |
async function main(){ |
View Creating_a_contact.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Initiate the Openscreen node SDK and include the project ID that you recieved using the Openscreen dashboard | |
const { Openscreen } = require("@openscreen/sdk"); | |
require('dotenv').config(); | |
const os = new Openscreen().config({key: process.env.OS_API_KEY, secret: process.env.OS_API_SECRET}); | |
const projectId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'; | |
const scanId = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'; | |
async function main(){ |
OlderNewer