Skip to content

sesam-community/o365graph

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

93 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

o365graph

Connector for Sesam to use the Microsoft Graph Api

Environment variables

Required

  • client_id
  • client_secret
  • grant_type
  • resource
  • entities_path
  • next_page
  • token_url

Optional

  • log_level
  • base_url
  • sleep
  • sharepoint_url

URL routes

/entities/

generic endpoint to return all types of entities based on the given graph url. Graph Explorer is your friend.

GET request will return entities based on the given relative url

/file/

This endpoint requires the env var 'sharepoint_url'

It uses the default document library "Shared Documents". To specify a different document library, add a section to the path after the site/team with /doclib:MyFancyDocumentLib/ i.e. teams/SesamTeam/doclib:SpecialLib/folder2/my_awesome_file.pdf

GET request with a file path will return the file bytes GET request with a directory path will return metadata for all files in directory path POST request will write file to the given file path

/metadata/

This endpoint requires the env var 'sharepoint_url'

It uses the default document library "Shared Documents". To specify a different document library, add a section to the path after the site/team with /doclib:MyFancyDocumentLib/ i.e. teams/SesamTeam/doclib:SpecialLib/folder2/my_awesome_file.pdf

POST request writes metadata to the given document file path (Managed metadata currently not supported) Payload must be in the following format:

{
  "my_column": "Some value"
}

/user-image/

Specify image upload location in path. The path needs to contain placeholder {user} which will be replaced by user ID or UPN from payload attribute "user" i.e. /user-image/users/{user}/photo/$value

Payload must contain the following:

{
  "user": "O365 user id or userPrincipalName",
  "image": "base64 encoded image data"
}

About

connector for sesam to Office 365 graph

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 98.9%
  • Dockerfile 1.1%