{"activeVersionTag":"latest","latestAvailableVersionTag":"latest","collection":{"info":{"_postman_id":"8bab41bc-9f34-4d48-a214-4a201373baff","name":"PRINTgenie SSO","description":"# Authentication\n\nBefore you can utilize these APIs, you need to obtain your client credentials. To start this process, please email us at [help@printgenie.io](https://mailto:help@printgenie.io) or contact us in the PRINTgenie slack to request access to the SSO feature. We'll collaborate with you to set up credentials that best match your customer experience goals.\n\nOnce registered, you'll receive a client-specific API key. This key is used for authenticating your requests to our API. You should include this key in each SSO request header as follows:\n\n```\nx-api-key: {your api key}\n\n ```\n\nThis key authenticates your requests and allows you to utilize the features of the SSO and list import APIs. Please ensure you store this key securely and do not share it publicly to maintain the security of your API access.\n\n# Quick Start Guide\n\nThis guide is intended for third-party developers looking to utilize our Single Sign-On (SSO) and list import API collection.\n\n## Overview\n\nPRINTgenie simplifies the registration and sign-in process by leveraging automated client-specific registration configurations. We offer a variety of subscription levels, industry settings, and user-affiliation settings that can be configured when requesting your API keys.\n\nOnce configured, you can utilize our SSO API to authenticate any user associated with your API key. If successful, the API will return a JWT session encoded login URL that can be used to SSO a user into the PRINTgenie platform for the next 15 minutes.\n\nAdditionally, PRINTgenie's SSO feature allows for data import functionality. You can attach leads or contact data to the login session to streamline the marketing process for your users with your own data!\n\n## Steps for SSO Operation with Custom Data Sessions\n\nHere's an example of how you would perform a SSO operation with custom data sessions. This is helpful if you want to send a user over to PRINTgenie with a contact list so they can skip the data farming side of PRINTgenie and get stright to marketing!\n\nThis is of course optional, if you're just looking to login a user directly, you can simply call the login API directly.\n\n### 1\\. Get Upload Session Details\n\nCall our data upload `https://api.printgenie2.io/sso/csv-upload` with an HTTP GET method. This will provide you with your upload session details (`csv_upload_url`) and the upload location (`csv_cdn_url`).\n\n### 2\\. Upload Your Data\n\nNext, use the `csv_upload_url` with an HTTP PUT method to upload your raw data directly to our AWS S3 storage.\n\nThese are the required headers for your CSV:\n\n```\n\"Mail Address\", \"Mailing City\", \"Mailing State\", \"Mailing Zip Code\"\n\n ```\n\n  \nAdditonal headers may be supplied; they will be imported into PRINTgenie as 'variable data' and will remain be accessible to PRINTgenie templates.\n\n### 3\\. Perform the SSO Login Request with your csv_cdn_url\n\nIf your HTTP PUT is successful, you can now use the `csv_cdn_url` in your SSO login request. If done correctly, the user will now see a data import triggered during their sign-in process. Please note that the `csv_cdn_url` should be added to the root of your login request payload.\n\n## SSO Execution Flow Diagram\n\n<img src=\"https://content.pstmn.io/95faaf28-cf94-4332-a576-c80783444be8/VW50aXRsZWQgZGlhZ3JhbS0yMDI1LTEyLTEzLTAxMzgyMS5wbmc=\">","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","isPublicCollection":false,"owner":"5626353","team":1980083,"collectionId":"8bab41bc-9f34-4d48-a214-4a201373baff","publishedId":"2s946o395R","public":true,"publicUrl":"https://documenter-api.postman.tech/view/5626353/2s946o395R","privateUrl":"https://go.postman.co/documentation/5626353-8bab41bc-9f34-4d48-a214-4a201373baff","customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"documentationLayout":"classic-double-column","customisation":{"metaTags":[{"name":"description","value":""},{"name":"title","value":""}],"appearance":{"default":"light","themes":[{"name":"dark","logo":null,"colors":{"top-bar":"212121","right-sidebar":"303030","highlight":"FF6C37"}},{"name":"light","logo":null,"colors":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"}}]}},"version":"8.12.12","publishDate":"2023-07-25T01:59:57.000Z","activeVersionTag":"latest","documentationTheme":"light","metaTags":{"title":"","description":""},"logos":{"logoLight":null,"logoDark":null}},"statusCode":200},"environments":[{"name":"PROD:  pg-api-services","id":"2b673765-08fe-4785-959a-2b7f32b1d8c4","owner":"5626353","values":[{"key":"domain","value":"https://aws.printgenie.io","enabled":true},{"key":"version","value":"pg-api-services","enabled":true},{"key":"serverless-domain","value":"https://api.printgenie2.io","enabled":true,"type":"default"},{"key":"partner-key","value":"7a566f32-2a8c-11ee-be56-0242ac120002","enabled":true,"type":"default"}],"published":true}],"user":{"authenticated":false,"permissions":{"publish":false}},"run":{"button":{"js":"https://run.pstmn.io/button.js","css":"https://run.pstmn.io/button.css"}},"web":"https://www.getpostman.com/","team":{"logo":"https://postman-image-service.postman.com/api/cloudinary-proxy/postman/image/upload/t_team_logo_pubdoc/v1/team/aef3364911974213376cec42ca39fc9bd00601b0aac417a5b404fd320243e73e","favicon":""},"isEnvFetchError":false,"languages":"[{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"HttpClient\"},{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"RestSharp\"},{\"key\":\"curl\",\"label\":\"cURL\",\"variant\":\"cURL\"},{\"key\":\"dart\",\"label\":\"Dart\",\"variant\":\"http\"},{\"key\":\"go\",\"label\":\"Go\",\"variant\":\"Native\"},{\"key\":\"http\",\"label\":\"HTTP\",\"variant\":\"HTTP\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"OkHttp\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"Unirest\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"Fetch\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"jQuery\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"XHR\"},{\"key\":\"c\",\"label\":\"C\",\"variant\":\"libcurl\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Axios\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Native\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Request\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Unirest\"},{\"key\":\"objective-c\",\"label\":\"Objective-C\",\"variant\":\"NSURLSession\"},{\"key\":\"ocaml\",\"label\":\"OCaml\",\"variant\":\"Cohttp\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"cURL\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"Guzzle\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"HTTP_Request2\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"pecl_http\"},{\"key\":\"powershell\",\"label\":\"PowerShell\",\"variant\":\"RestMethod\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"http.client\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"Requests\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"httr\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"RCurl\"},{\"key\":\"ruby\",\"label\":\"Ruby\",\"variant\":\"Net::HTTP\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"Httpie\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"wget\"},{\"key\":\"swift\",\"label\":\"Swift\",\"variant\":\"URLSession\"}]","languageSettings":[{"key":"csharp","label":"C#","variant":"HttpClient"},{"key":"csharp","label":"C#","variant":"RestSharp"},{"key":"curl","label":"cURL","variant":"cURL"},{"key":"dart","label":"Dart","variant":"http"},{"key":"go","label":"Go","variant":"Native"},{"key":"http","label":"HTTP","variant":"HTTP"},{"key":"java","label":"Java","variant":"OkHttp"},{"key":"java","label":"Java","variant":"Unirest"},{"key":"javascript","label":"JavaScript","variant":"Fetch"},{"key":"javascript","label":"JavaScript","variant":"jQuery"},{"key":"javascript","label":"JavaScript","variant":"XHR"},{"key":"c","label":"C","variant":"libcurl"},{"key":"nodejs","label":"NodeJs","variant":"Axios"},{"key":"nodejs","label":"NodeJs","variant":"Native"},{"key":"nodejs","label":"NodeJs","variant":"Request"},{"key":"nodejs","label":"NodeJs","variant":"Unirest"},{"key":"objective-c","label":"Objective-C","variant":"NSURLSession"},{"key":"ocaml","label":"OCaml","variant":"Cohttp"},{"key":"php","label":"PHP","variant":"cURL"},{"key":"php","label":"PHP","variant":"Guzzle"},{"key":"php","label":"PHP","variant":"HTTP_Request2"},{"key":"php","label":"PHP","variant":"pecl_http"},{"key":"powershell","label":"PowerShell","variant":"RestMethod"},{"key":"python","label":"Python","variant":"http.client"},{"key":"python","label":"Python","variant":"Requests"},{"key":"r","label":"R","variant":"httr"},{"key":"r","label":"R","variant":"RCurl"},{"key":"ruby","label":"Ruby","variant":"Net::HTTP"},{"key":"shell","label":"Shell","variant":"Httpie"},{"key":"shell","label":"Shell","variant":"wget"},{"key":"swift","label":"Swift","variant":"URLSession"}],"languageOptions":[{"label":"C# - HttpClient","value":"csharp - HttpClient - C#"},{"label":"C# - RestSharp","value":"csharp - RestSharp - C#"},{"label":"cURL - cURL","value":"curl - cURL - cURL"},{"label":"Dart - http","value":"dart - http - Dart"},{"label":"Go - Native","value":"go - Native - Go"},{"label":"HTTP - HTTP","value":"http - HTTP - HTTP"},{"label":"Java - OkHttp","value":"java - OkHttp - Java"},{"label":"Java - Unirest","value":"java - Unirest - Java"},{"label":"JavaScript - Fetch","value":"javascript - Fetch - JavaScript"},{"label":"JavaScript - jQuery","value":"javascript - jQuery - JavaScript"},{"label":"JavaScript - XHR","value":"javascript - XHR - JavaScript"},{"label":"C - libcurl","value":"c - libcurl - C"},{"label":"NodeJs - Axios","value":"nodejs - Axios - NodeJs"},{"label":"NodeJs - Native","value":"nodejs - Native - NodeJs"},{"label":"NodeJs - Request","value":"nodejs - Request - NodeJs"},{"label":"NodeJs - Unirest","value":"nodejs - Unirest - NodeJs"},{"label":"Objective-C - NSURLSession","value":"objective-c - NSURLSession - Objective-C"},{"label":"OCaml - Cohttp","value":"ocaml - Cohttp - OCaml"},{"label":"PHP - cURL","value":"php - cURL - PHP"},{"label":"PHP - Guzzle","value":"php - Guzzle - PHP"},{"label":"PHP - HTTP_Request2","value":"php - HTTP_Request2 - PHP"},{"label":"PHP - pecl_http","value":"php - pecl_http - PHP"},{"label":"PowerShell - RestMethod","value":"powershell - RestMethod - PowerShell"},{"label":"Python - http.client","value":"python - http.client - Python"},{"label":"Python - Requests","value":"python - Requests - Python"},{"label":"R - httr","value":"r - httr - R"},{"label":"R - RCurl","value":"r - RCurl - R"},{"label":"Ruby - Net::HTTP","value":"ruby - Net::HTTP - Ruby"},{"label":"Shell - Httpie","value":"shell - Httpie - Shell"},{"label":"Shell - wget","value":"shell - wget - Shell"},{"label":"Swift - URLSession","value":"swift - URLSession - Swift"}],"layoutOptions":[{"value":"classic-single-column","label":"Single Column"},{"value":"classic-double-column","label":"Double Column"}],"versionOptions":[],"environmentOptions":[{"value":"0","label":"No Environment"},{"label":"PROD:  pg-api-services","value":"5626353-2b673765-08fe-4785-959a-2b7f32b1d8c4"}],"canonicalUrl":"https://documenter.gw.postman.com/view/metadata/2s946o395R"}