Skip to content

Instantly share code, notes, and snippets.

@dkarchmer
dkarchmer / cognito-developer-authenticated-client-example.py
Last active October 11, 2024 16:44
django-boto3-cognito: AWS' Cognito Developer Authenticated Identities Authflow using Django/Python/Boto3 (For building stand-alone clients)
__author__ = 'dkarchmer'
'''
This script emulates a stand-alone Python based client. It relies on Boto3 to access AWS, but
requires your Django server to have an API for your user to access Cognito based credentials
Because of Cognito, the client (this script) will only get temporary AWS credentials associated
to your user and only your user, and based on whatever you configure your AIM Policy to be.
Most Cognito examples demonstrate how to use Cognito for Mobile Apps, so this scripts demonstrate
how to create a stand-alone Python script but operating similarly to these apps.
@majelbstoat
majelbstoat / spanner.d.ts
Created June 28, 2018 02:17
Typescript types for @google-cloud/spanner, based on v1.4.0 documentation
// Type definitions for Google Cloud Spanner 1.4
// Project: https://github.com/googleapis/nodejs-spanner
// Definitions by: Jamie Talbot <https://github.com/majelbstoat>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.7
/// <reference types="node"/>
declare module '@google-cloud/spanner' {
export type SpannerDate = object