Skip to content

Add Document API#46

Merged
som-m merged 4 commits intoomise:masterfrom
som-m:document-api
Feb 10, 2021
Merged

Add Document API#46
som-m merged 4 commits intoomise:masterfrom
som-m:document-api

Conversation

@som-m
Copy link
Copy Markdown
Contributor

@som-m som-m commented Feb 4, 2021

Summary

  • Add to Dispute (Omise doc)
    • Create a document
    • List documents
  • Add Document API (Omise doc)
    • Retrieve
    • Reload
    • Destroy
  • Add tests

QA

You should be able to do the following actions.

  • Create a document

    • Retrieve a dispute
      dispute = omise.Dispute.retrieve('dspt_test_5mtsn1g8iplijhmlkpe')
    • Add a document to the dispute
      files = {'file': open('evidence.png', 'rb')}
      document = dispute.upload_document(files)
  • List documents
    documents = dispute.list_documents()

  • Retrieve a document
    document = dispute.documents.retrieve('docu_test_5mtsqwj0lbak4qsfrcj')

  • Reload a document
    document.reload()

  • Destroy a document
    document.destroy()

@som-m som-m marked this pull request as ready for review February 5, 2021 11:41
@som-m som-m merged commit baabea7 into omise:master Feb 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants