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
{ | |
"status": "Success", | |
"data": { | |
"data": { | |
"checkoutFlows": [ | |
{ | |
"brand": { | |
"name": "The New Yorker", | |
"slug": "the-new-yorker" | |
}, |
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
exports = async function() { | |
// Supply projectID and clusterNames... | |
const projectID = '<your Atlas project id>'; | |
const clusterNames = ['<your cluster names>']; | |
// Get stored credentials... | |
console.log(context.values.get("AtlasPrivateKey")) | |
const username = context.values.get("AtlasPublicKey"); | |
const password = context.values.get("AtlasPrivateKey"); |
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
# AWS SSO Get temprory AWS credentials | |
# Add to your bash profile | |
# usage: AWS_PROFILE=<aws_profile> aws_sso_creds | |
aws_sso_creds() { | |
local account_id role_name access_token sso_region profile_region temp_creds | |
echo "Logging in to profile: ${AWS_PROFILE}" | |
aws sso login --profile ${AWS_PROFILE} |
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
MIMB8SQGCSqGSIb3DQEHAqCDAfEUMIMB8Q8CAQExCzAJBgUrDgMCGgUAMIMB4MIGCSqGSIb3DQEHAaCDAeCyBIMB4K0xgwHgqDAKAgEIAgEBBAIWADAKAgEUAgEBBAIMADALAgEBAgEBBAMCAQAwCwIBAwIBAQQDDAE3MAsCAQsCAQEEAwIBADALAgEPAgEBBAMCAQAwCwIBEAIBAQQDAgEAMAsCARkCAQEEAwIBAzAMAgEKAgEBBAQWAjQrMAwCAQ4CAQEEBAICAQAwDQIBDQIBAQQFAgMCcQAwDQIBEwIBAQQFDAMxLjAwDgIBCQIBAQQGAgRQMjU2MBgCAQQCAQIEENM+ZgDVmu05o5qDDGqzAX8wGwIBAAIBAQQTDBFQcm9kdWN0aW9uU2FuZGJveDAcAgEFAgEBBBQxwUf3oXRidId3oaVznGpx8q0MzTAeAgEMAgEBBBYWFDIwMjItMTAtMTlUMTM6MzM6MjJaMB4CARICAQEEFhYUMjAxMy0wOC0wMVQwNzowMDowMFowIQIBAgIBAQQZDBdjb20uY29uZGVuZXQuRXBpY3VyaW91czBVAgEHAgEBBE0HOx9ezVHEfTaOiszoQphSl5zjvZc40aWR5YrPCKuPH3lzTi8d2wvADMcnNYHVvCVTqLswlIYI+5K1sqHGP0falTF1tIxWQaVZcz3GEDBXAgEGAgEBBE\/5zBlNi2bAF21mHUquhDZFBgvZV4RoeAm54aB4T5fmAAhvpA7b3DPUj8lt\/Ra8FnPAaA+XbikRGZLLmXyhJEqvfukG6FoHcH+h2RrxojvhMIIBoQIBEQIBAQSCAZcxggGTMAsCAgatAgEBBAIMADALAgIGsAIBAQQCFgAwCwICBrICAQEEAgwAMAsCAgazAgEBBAIMADALAgIGtAIBAQQCDAAwCwICBrUCAQEEAgwAMAsCAga2AgEBBAIMADAMAgIGpQIBAQQDAgEBMAwCAgarAgEBBAMCAQMwDAICBq4CAQEEAwIBADAMAgIGsQ |
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 subscriptionEvent = new mongoose.Schema({ | |
martechId: { | |
type: String, | |
required: true, | |
}, | |
subscriptionId: { | |
type: String, | |
required: true, | |
}, | |
clientId: { |
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
<html> | |
<head> | |
<meta name="description" content="full-stack engineer challenge" /> | |
<title>Coding Challenge</title> | |
<style id="jsbin-css"> | |
body { | |
font-family: Arial; | |
font-size: 80%; | |
} |
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 SNS = require('./sns'); | |
const sns = new SNS(); | |
function smsSubscriber(data) { | |
console.log(`send sms for transaction: ${data.transactionId}`); | |
return 'sms'; | |
} | |
async function emailSubscriber(data) { | |
//await fetch('/email'); |
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 names = ['Huey', 'Dewey', 'Louie', 'Donald', 'Launchpad']; | |
const moreNames = ['Donald', 'Mickey', 'Minnie', 'Goofy', 'Chip', 'Dale']; | |
/** | |
* Find common names in two arrays of names | |
* @param names1 | |
* @param names2 | |
* @returns {[]} names contained in both arrays | |
*/ | |
const findCommonNames = (names1, names2) => { |
This file has been truncated, but you can view the full file.
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
{"type":2300,"data":{"_id":"people/57698912526852117","_key":"57698912526852117","_rev":"_XxFNZIy--_","created":"2018-11-20T15:47:51.382Z","externalIds":[{"id":"55c64f6ec4e6a2d8dcde5f62","source":"fashionshow"}],"name":"Ken Downing","roles":["CELEBRITY"],"status":"active","updated":"2018-11-20T15:47:51.382Z"}} | |
{"type":2300,"data":{"_id":"people/57698912526855622","_key":"57698912526855622","_rev":"_XxFNZ7W--_","created":"2018-11-20T15:47:51.382Z","externalIds":[{"id":"55c64f5ac4e6a2d8dcde5aae","source":"fashionshow"}],"name":"Jesper Lund","roles":["MODEL"],"status":"active","updated":"2018-11-20T15:47:51.382Z"}} | |
{"type":2300,"data":{"_id":"people/57698912526844744","_key":"57698912526844744","_rev":"_XxFNQ0e--_","created":"2018-11-20T15:47:51.382Z","externalIds":[{"id":"5a934edf1a71770bab842f09","source":"fashionshow"}],"name":"Alena Podloznaya","roles":["MODEL"],"status":"active","updated":"2018-11-20T15:47:51.382Z"}} | |
{"type":2300,"data":{"_id":"people/57698912526854790","_key":"57698912526854790","_rev":"_X |
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
{"indexes":[{"fields":["name"],"id":"3215362","minLength":2,"sparse":true,"type":"fulltext","unique":false},{"deduplicate":true,"fields":["name"],"id":"3215365","selectivityEstimate":1,"sparse":false,"type":"hash","unique":true},{"deduplicate":true,"fields":["status"],"id":"3215368","selectivityEstimate":1,"sparse":false,"type":"hash","unique":false},{"deduplicate":true,"fields":["roles"],"id":"3215371","selectivityEstimate":1,"sparse":false,"type":"hash","unique":false},{"deduplicate":true,"fields":["alternativeNames"],"id":"4305927","selectivityEstimate":1,"sparse":false,"type":"hash","unique":false}],"parameters":{"allowUserKeys":true,"cid":"5598711","count":0,"deleted":false,"doCompact":true,"globallyUniqueId":"h7763A8B08E5E/1300145","id":"5598711","indexBuckets":8,"indexes":[{"fields":["_key"],"id":"0","selectivityEstimate":1,"sparse":false,"type":"primary","unique":true},{"fields":["name"],"id":"3215362","minLength":2,"sparse":true,"type":"fulltext","unique":false},{"deduplicate":true,"fields":["name"], |
NewerOlder