• Stars
    star
    653
  • Rank 68,968 (Top 2 %)
  • Language
    Swift
  • License
    MIT License
  • Created over 8 years ago
  • Updated over 5 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A Swift framework for working with emails

Build Status Carthage Pods Swift 5.0 Platforms

Postal is a swift framework providing simple access to common email providers.

Example

Connect

let postal = Postal(configuration: .icloud(login: "[email protected]", password: "mypassword"))
postal.connect { result in
    switch result {
    case .success:
        print("success")
    case .failure(let error):
        print("error: \(error)")
    }
}

Search

let filter = .subject(value: "Foobar") && .from(value: "[email protected]")
postal.search("INBOX", filter: filter) { result in
    switch result {
    case .success(let indexes):
        print("success: \(indexes)")
    case .failure(let error):
        print("error: \(error)")
    }
}

Fetch

let indexset = NSIndexSet(index: 42)
postal.fetchMessages("INBOX", uids: indexset, flags: [ .headers ], onMessage: { email in
    print("new email received: \(email)")
}, onComplete: error in
    if error = error {
        print("an error occured: \(error)")
    }
}

Want to debug your IMAP session ?

postal.logger = { log in
    print(log)
}

What about Mailcore ?

Postal does not address the same goal as MailCore. You can take a look at our thoughts in the TechnicalNotes document.

Provider quirks

Email protocol is standardized. However providers implementations often provides extension or variations of these standards. We tried to build a document to synthesize working around these variations here: ProviderQuirks.

Contributing

Postal has been a great effort and we could really use your help on many areas:

  • Finding and reporting bugs.
  • New feature suggestions.
  • Answering questions on issues.
  • Documentation improvements.
  • Reviewing pull requests.
  • Fixing bugs/new features.
  • Improving tests.
  • Contribute to elaborate the Roadmap.

If any of that sounds cool to you, please send a pull request!

Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms that you can find here: CodeOfConduct.

Requirements

  • Xcode 10
  • OS X 10.10 or later
  • iOS 8.0 or later

Installation

Carthage

Postal is Carthage compatible.

  • Add github "snipsco/Postal" to your Cartfile.
  • Run carthage update.

CocoaPods

Postal also can be used by CocoaPods.

  • Add the followings to your Podfile:
use_frameworks!
pod 'Postal'
  • Run pod install.

Manual

  1. Add the Postal repository as a submodule of your application’s repository.
git submodule add https://github.com/snipsco/Postal.git
git submodule update --init --recursive
  1. Drag and drop Postal.xcodeproj into your application’s Xcode project or workspace.
  2. On the β€œGeneral” tab of your application target’s settings, add Postal.framework to the β€œEmbedded Binaries” section.
  3. If your application target does not contain Swift code at all, you should also set the EMBEDDED_CONTENT_CONTAINS_SWIFT build setting to β€œYes”.

License

Postal is released under the MIT License.

More Repositories

1

snips-nlu

Snips Python library to extract meaning from text
Python
3,889
star
2

snips-nlu-rs

Snips NLU rust implementation
Rust
340
star
3

ntm-lasagne

Neural Turing Machines library in Theano with Lasagne
Python
300
star
4

awesome-snips

A curated list of awesome Snips projects
276
star
5

tensorflow-build

A set of scripts to (cross-)build the Tensorflow C lib for various architectures / OS
Shell
178
star
6

rust-threshold-secret-sharing

A pure-Rust implementation of various threshold secret sharing schemes
Rust
156
star
7

react-inview-monitor

Declarative in-view scroll monitor for React JS
JavaScript
114
star
8

rust-paillier

A pure-Rust implementation of the Paillier encryption scheme
Rust
80
star
9

snips-nlu-ontology

Ontology of Snips NLU
Rust
57
star
10

react-scrolling-color-background

background with color transitioning as you scroll, declarative and easy to setup
JavaScript
57
star
11

sda

Secure distributed aggregation of high-dimensional vectors
Rust
55
star
12

snips-skill-respeaker

Official Snips Animation Feedback For Makers Kits/Dev Kits, supporting all kinds of APA102 based LED hardwares.
C
41
star
13

snips-record-personal-hotword

Python
40
star
14

hermes-protocol

Definition of the Hermes protocol used by the Snips platform
Rust
36
star
15

snips-nlu-language-resources

Language resources for the Snips Natural Language Understanding (NLU)
Python
34
star
16

snips-platform-android-demo

A demo of the Snips Platform for Android
Java
22
star
17

paillier-libraries-benchmarks

Companion repository for blog post on benchmarking implementations of Paillier encryption
Go
19
star
18

SuperCombinators

[Deprecated] A Swift parser combinator framework
Swift
19
star
19

nlp-workshops

Introduction and tutorial about Natural Language Processing
Jupyter Notebook
16
star
20

snipsmanager

The Snips Assistant Manager
Python
16
star
21

snips-nlu-parsers

Rust crate for entity parsing
Rust
16
star
22

gazetteer-entity-parser

Rust library for parsing and resolving entity values based on a gazetteer
Rust
16
star
23

snips-issues

Feel free to share your bugs with us.
14
star
24

snips-app-sonos

Sonos app for Snips
Python
13
star
25

snips-nlu-metrics

Python package to compute metrics on an NLU intent parsing pipeline
Python
13
star
26

snips-nlu-utils

Rust library for NLU utils with wrappers in other languages
Rust
12
star
27

snips-app-template-py

Action code template written in Python.
Python
11
star
28

snips-platform-swift

The Swift framework for the Snips Platform
Swift
11
star
29

snips-actions-templates

Template files for snips actions
Python
11
star
30

snips-nlu-resources

10
star
31

play-mongo-bson

Scala client for MongoDB using macros for case class serialization/deserialization
Scala
10
star
32

snips-platform-docker

Shell
10
star
33

snips-skill-owm

OpenWeatherMap skill for Snips
Python
9
star
34

snips-javascript-toolkit

Everything you need in order to write Snips actions in javascript / typescript.
TypeScript
9
star
35

snips-skill-hue

Philips Hue skill for Snips
Python
8
star
36

create-snips-action

Generator for writing Snips action code in Javascript/Typescript.
JavaScript
7
star
37

crfsuite-rs

Rust bindings for CRFSuite
C
7
star
38

snips-jeedom-plugin

Jeedom plugin allows connecting Snips voice assistant with Jeedom platform.
PHP
6
star
39

snips-demo-dev-kit

Official action code for Snips Voice Interaction Development Kit. (Temperature & Relay)
Python
6
star
40

snips-javascript-actions-runner

A lightweight javascript actions runner. πŸƒβ€β™‚οΈ
JavaScript
5
star
41

ripb

A rust crate providing an implementation of a lock-free type-safe in-process bus.
Rust
4
star
42

snips-action-alarm

Snips action code for the Alarm app
TypeScript
4
star
43

snipsmanagercore

Core Python utilities for the Snips Manager
Python
4
star
44

snips-skill-fakeweather

Fake weather forecasts for Snips
Python
3
star
45

snips-app-relay-switch

Control the switch connected on Raspberry Pi by using your voice.
Python
3
star
46

snips-skill-weather

skill for the Snips assistant, En & Fr
JavaScript
2
star
47

snips-skill-weather-tts

Skill to show how to parse a weather intent and respond with a TTS.
Python
2
star
48

snips-skill-neopixel

NeoPixel Ring 24 skill for Snips
Python
2
star
49

snips-app-sht31

Get temperature and humidity from SHT31 (I2C protocol) by using your voice.
Python
2
star
50

snips-actions-runner-hook

Temporary solution to link snips-skill-server and snips-actions-runner
JavaScript
1
star
51

braccio_arm_demo

Code to control the braccio robotic arm for maker fare
Python
1
star
52

snips-action-reminder

Snips action code for the Reminder app
TypeScript
1
star
53

snips-action-timer

Snips action code for the Timer app
TypeScript
1
star
54

snips-action-unit-converter

Snips action code for the Unit Converter app
TypeScript
1
star
55

snips-action-nutrition

Snips action code for the Nutrition app
TypeScript
1
star
56

homebrew-snips

Snips formulae for the Homebrew package manager
Ruby
1
star
57

snipsair_whitepaper

Snips whitepapers, summaries, traductions etc.. Get in touch if you would like to help translate!
1
star
58

snips-skill-hue-pro

Handler for [Smart Light - Hue] bundle.
Python
1
star
59

SDP-swift

Swift reference implementation for Simple Datagram Protocol.
Swift
1
star
60

create-snips-action-typescript

Generator for writing Snips action code in Typescript.
TypeScript
1
star
61

Snips_Lights

Arduino library for light animations for the smart speaker project.
C++
1
star
62

snips-skill-times-tables-quiz

This skill enable your snips voice assistant to give you a quiz on times tables under the form of a dialog session.
Python
1
star