- Notifications
You must be signed in to change notification settings - Fork0
codeversedev/sky-api-tutorial-auth-code-php
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Blackbaud SKY API Authorization Code Flow demo application.
This code sample is a very basic example of how to interact with the Blackbaud OAuth 2.0 Service. You are free to choose the client library and method that best suit your needs when creating production-level applications.
The Blackbaud SKY API currently supports theAuthorization Code Flow, which requires a back-end server component to securely store the client secret. For this code sample, we've implemented the server component using PHP.
We've stripped down the user interface to highlight the Authorization Code Flow. OurBarkbaud code samples provide a rich user interface usingSKY UX.
Feel free to leave feedback by filing anissue.
A local running Apache server to run and host the project. For this example we recommend you install and run the project usingMAMP.
To run this application in your environment, follow theAuth Code Flow Tutorial instructions within our documentation.
PHP sample coming soon. Follow the instructions for obtaining the necessary keys from the other code samples.
1. Clone the repo.2. Copy the `config.php.sample` file to `config.php`. Fill in the keys obtained from your Developer Account and registered application.3. Run MAMP.4. MAMP `Preferences` -> `Web Server` -> Set the `Document Root` to point to the location of your cloned project.5. MAMP `Start Servers`.6. Open your browser to `http://localhost:8888`.
First, construct the request data object.
let patchData = { constituent_id: 280, first: 'Robert'};
Then, pass the request into the request'sdata
property as a JSON string.
$http({ method: 'patch', url: '/api/constituents.php', data: `data=${JSON.stringify(patchData)}`, headers : { 'Content-Type': 'application/x-www-form-urlencoded' }}).then(res => { console.log(res.data.status); // success});
About
Authorization Code Flow example using php
Resources
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Releases
Packages0
Languages
- PHP56.5%
- HTML43.5%