SimpleiCloud is a lightweight iCloud client for Python, currently focused exclusively on managing contacts.
Project description
SimpleICloud
SimpleiCloud is a lightweight iCloud client for Python, currently focused exclusively on managing contacts.
Unlike other libraries — such as the excellent PyiCloud — SimpleiCloud aims to support a broader set of contact-related use cases, including creating, updating, and deleting contacts.
SimpleiCloud is powered by requests HTTP library.
This module is under active development, and we welcome contributions from the community.
Examples
You must use an app-specific password for iCloud (generate it at https://appleid.apple.com/ > Sign-In & Security > App-Specific Passwords)
Class instantiating
simpleicloudservice = SimpleICloudService(
username="user@domain.com",
password="secret_P422sword,
)
Get a contact
contact = simpleicloudservice.get_contact("F4ZZZZ0-EZZ7-4ZZD-8ZZE-C4FZZZZZZACD")
Get all contacts
contacts_list = simpleicloudservice.get_all_contacts()
Delete a contact
contact = simpleicloudservice.delete_contact("F4ZZZZ0-EZZ7-4ZZD-8ZZE-C4FZZZZZZACD")
Create a contact
create the vCard
import uuid
import vobject
v = vobject.vCard()
v.add("fn").value = "Pippo DePippis"
# don't ask me why but iCloud need the following!
# credits to https://github.com/pimutils/vdirsyncer/issues/1145#issuecomment-2464999129
v.add("n").value = vobject.vcard.Name(family="DePippis", given="Pippo")
phone = v.add("tel")
phone.value = phone_
phone.type_param = "CELL"
email = v.add("email")
email.value = "pippo.depippis@xyz.abc
email.type_param = ["INTERNET", "HOME", "pref"]
uuid_ = str(uuid.uuid4())
v.add("uid").value = uuid_
create the contact in iCloud
simpleicloudservice.create_contact(vcard=vv)
Update a contact
edit the contact's feature
email = v.add("email")
email.value = "blabla@aaa.com"
email.type_param = ["INTERNET", "HOME", "pref"]
update the contact in iCloud
simpleicloudservice.update_contact(v)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file simple_icloud-0.1.1.tar.gz.
File metadata
- Download URL: simple_icloud-0.1.1.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b05fabc4f0f2f1139cb16d0e8bba2b34a27be4196c784f5889ebb78d2f55ae2d
|
|
| MD5 |
2f273242d44425229a20cfdf2db7120c
|
|
| BLAKE2b-256 |
5a7714e623c8d434f722785974666bdaf883caef41da07acf0056c684f3e3d66
|
Provenance
The following attestation bundles were made for simple_icloud-0.1.1.tar.gz:
Publisher:
publish.yml on luca-ferreri/simple-icloud
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
simple_icloud-0.1.1.tar.gz -
Subject digest:
b05fabc4f0f2f1139cb16d0e8bba2b34a27be4196c784f5889ebb78d2f55ae2d - Sigstore transparency entry: 203556341
- Sigstore integration time:
-
Permalink:
luca-ferreri/simple-icloud@caefa09db7ec0ed8670a65841f435457f3f4a482 -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/luca-ferreri
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@caefa09db7ec0ed8670a65841f435457f3f4a482 -
Trigger Event:
push
-
Statement type:
File details
Details for the file simple_icloud-0.1.1-py3-none-any.whl.
File metadata
- Download URL: simple_icloud-0.1.1-py3-none-any.whl
- Upload date:
- Size: 7.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8a813eb47d4d813d76d6618faf6f86541a2400099de40cd6eb1bfadd7b22e169
|
|
| MD5 |
1879fb528749a27fcaede5ab6c36dcfa
|
|
| BLAKE2b-256 |
88984878c87ea5d97ae294c7baa4c9639217a5f6756c7ac0272f290dae33a5b9
|
Provenance
The following attestation bundles were made for simple_icloud-0.1.1-py3-none-any.whl:
Publisher:
publish.yml on luca-ferreri/simple-icloud
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
simple_icloud-0.1.1-py3-none-any.whl -
Subject digest:
8a813eb47d4d813d76d6618faf6f86541a2400099de40cd6eb1bfadd7b22e169 - Sigstore transparency entry: 203556342
- Sigstore integration time:
-
Permalink:
luca-ferreri/simple-icloud@caefa09db7ec0ed8670a65841f435457f3f4a482 -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/luca-ferreri
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@caefa09db7ec0ed8670a65841f435457f3f4a482 -
Trigger Event:
push
-
Statement type: