Download the PHP package mhsaheb/google-calendar without Composer

On this page you can find all versions of the php package mhsaheb/google-calendar. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package google-calendar

Laravel Google Calendar API Package

This package provides a convenient way to interact with the Google Calendar API in Laravel applications. It allows you to create, update, delete, and retrieve events from a Google Calendar.

Installation

You can install this package via Composer by running the following command:

composer require mhsaheb/google-calendar

Configuration

php artisan vendor:publish --tag=config

This command will create a google-calendar.php file in your config directory. Open the file and provide your Google API credentials and other required information.

Usage

To use this package, you need to create an instance of the GoogleEvent class, which extends the GoogleCalendar class. Here's an example of how to create a new event:

You can also retrieve a list of events or get a specific event using the following methods:

To update or delete an event, you can use the respective methods:

Please note that you need to set up your Google Calendar API credentials correctly in the configuration file for these methods to work.

Using Google Service Account

If you want to use the package with a Google Service Account, you need to follow these additional steps:

  1. Make sure you have a Google Workspace (formerly G Suite) account and access to the Google Console.
  2. Activate the Domain-wide Delegation for your service account:

    • Go to the Google Cloud Console.
    • Select your project and navigate to the "IAM & Admin" -> "Service Accounts" section.
    • Find your service account and click on the "Edit" button.
    • Enable the "Enable Domain-wide Delegation" option.
    • Save the changes.
  3. Obtain the client_email from your service account JSON key file.
  4. Activate the Domain-wide Delegation Policy:
    • Go to your Google Workspace Admin Console.
    • Navigate to "Security" -> "API Controls" -> "Domain-wide Delegation".
    • Click on "Add new" and enter your client_id.
    • Specify the scopes you want to grant access to (e.g., https://www.googleapis.com/auth/cloud-platform).
    • Save the changes.
  5. In your .env file, add the following variable with your client_email:

    GOOGLE_CALENDAR_IMPERSONATE=your-service-account-email@example.com

Contributing

If you encounter any issues or have suggestions for improvements, feel free to open an issue or submit a pull request on GitHub. We appreciate your contributions!

License

This package is open-source software licensed under the MIT license.


All versions of google-calendar with dependencies

PHP Build Version
Package Version
Requires google/apiclient Version ^2.15
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package mhsaheb/google-calendar contains the following files

Loading the files please wait ....