horacioibrahim / iugu-python Goto Github PK
View Code? Open in Web Editor NEWIugu python client for Iugu API
License: Apache License 2.0
Iugu python client for Iugu API
License: Apache License 2.0
Testando o Waffle.io para manter o projeto.
Horacio, acho que seria interessante se tivesse a opção de carregar o Token diretamente do settings.py do Django, teria como implementar isso? Poderia haver os seguintes dados no settings do Django:
IUGU_TOKEN = ''
IUGU_TOKEN_TEST = ''
IUGU_TEST = True
O sistema poderia acessar o settings do Django e capturar o Token direto de lá, exemplo:
from django.conf import settings
API_TOKEN = settings.IUGU_TOKEN_TEST if settings.IUGU_TEST else settings.IUGU_TOKEN
Nesse caso você poderia tentar carregar o settings.py, caso ocorra erro tentaria carregar o os.environ["IUGU_API_TOKEN"]
ou vice-versa.
To change the attributes dynamic. Currently it are predefined.
Hello,
When I create a simple slip_bank charge show me this error:
Environment:
Request Method: POST
Request URL: http://local.enota.com.br:8000/cursos/matricular/confirmar/
Django Version: 1.8.1
Python Version: 3.4.2
Installed Applications:
('django_extensions',
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'rest_framework',
'django_filters',
'social.apps.django_app.default',
'bootstrap3',
'crispy_forms',
'compressor',
'braces',
'accounts',
'core',
'cursos',
'assinatura',
'debug_toolbar')
Installed Middleware:
('django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'core.context_middleware.JSONMiddleware',
'debug_toolbar.middleware.DebugToolbarMiddleware')
Traceback:
File "/Users/fellipeh/.virtualenvs/enota/lib/python3.4/site-packages/django/core/handlers/base.py" in get_response
response = wrapped_callback(request, _callback_args, *_callback_kwargs)
return func(request, _args, *_kwargs)
return view_func(request, _args, *_kwargs)
payment = pagar_curso(request, id_user=request.user.id, id_curso=curso_id)
return view_func(request, _args, *_kwargs)
charge = client.create_charge(u.email, item)
results = self.__conn.post(urn, data)
return self.__validation(response)
results = json_load(response)
parse_constant=parse_constant, object_pairs_hook=object_pairs_hook, **kw)
s.**class**.**name**))
Exception Type: TypeError at /cursos/matricular/confirmar/
Exception Value: the JSON object must be str, not 'bytes'
Conforme atendimento de número 782 do suporte Iugu.com não é possível alterar customer de uma assinatura, assim evitar o envio (uma request) desnecessário se o cliente da lib estiver alterando somente customer de uma assinatura (subir uma exceção).
Add environment variable or instantiate the API_TOKEN. Currently this in config.py that deeply in inner install path.
Something:
token = os.environ["IUGU_API_TOKEN"]
or
client = IuguClass(token="XXX")
Iugu API accept zero as a valid price for a plan, but it's raising a IuguPlansException saying value_cents is required
Ao salvar um cliente com acento (ex: Jéssica) está aparecendo J?ssica no iugu, e em python está retornando J\xe9ssica
Create documentation using Sphinx and deploy in Read The Docs.
Quando criamos um método de pagamento para o cliente, mesmo recebendo uma response do Iugu, é possível perceber que o cliente ainda fica sem meio de pagamento no painel.
Por que não tem a possibilidade de editar o e-mail do cliente?
Outro detalhe, não há as variáveis cc_email e cpf_cnpj
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.