Skip to content

Commit

Permalink
corrected spelling
Browse files Browse the repository at this point in the history
  • Loading branch information
Abinaya-Shunmugavel committed Nov 14, 2024
1 parent 15bf303 commit 70f8e20
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
22 changes: 11 additions & 11 deletions plivo/resources/transcription.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,34 +14,34 @@ class Transcription(PlivoResource):
_name = 'Transcription'
_identifier_string = 'transcription_id'

def get_tanscription(self):
return self.client.transcriptions.get_tanscription(self.id, **to_param_dict(self.get_tanscription(), locals()))
def get_transcription(self):
return self.client.transcriptions.get_transcription(self.id, **to_param_dict(self.get_transcription(), locals()))

def create_tanscription(self):
return self.client.transcriptions.create_tanscription(self.id, **to_param_dict(self.create_tanscription(), locals()))
def create_transcription(self):
return self.client.transcriptions.create_transcription(self.id, **to_param_dict(self.create_transcription(), locals()))

def delete_tanscription(self):
return self.client.transcriptions.delete_tanscription(self.id, **to_param_dict(self.delete_tanscription(), locals()))
def delete_transcription(self):
return self.client.transcriptions.delete_transcription(self.id, **to_param_dict(self.delete_transcription(), locals()))


class Transcriptions(PlivoResourceInterface):
_resource_type = Transcription

@validate_args(transcription_id=[of_type(six.text_type)]
)
def get_tanscription(self, transcription_id, type=None):
def get_transcription(self, transcription_id, type=None):
if not type:
return self.client.request(
'GET', ('Transcription', transcription_id), is_voice_request=True)
else:
return self.client.request(
'GET', ('Transcription', transcription_id), to_param_dict(self.get_tanscription, locals()), is_voice_request=True)
'GET', ('Transcription', transcription_id), to_param_dict(self.get_transcription, locals()), is_voice_request=True)

def create_tanscription(self, recording_id, transcription_callback_url=None):
def create_transcription(self, recording_id, transcription_callback_url=None):
return self.client.request(
'POST', ('Transcription', recording_id), to_param_dict(self.create_tanscription, locals()), is_voice_request=True)
'POST', ('Transcription', recording_id), to_param_dict(self.create_transcription, locals()), is_voice_request=True)

def delete_tanscription(self, transcription_id):
def delete_transcription(self, transcription_id):
return self.client.request(
'DELETE', ('Transcription', transcription_id), is_voice_request=True)

Expand Down
6 changes: 3 additions & 3 deletions tests/resources/test_transcriptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class TranscriptionTest(PlivoResourceTestCase):
@with_response(200)
def test_get(self):

transcription = self.client.transcriptions.get_tanscription('e12d05fe-6979-485c-83dc-9276114dba3b')
transcription = self.client.transcriptions.get_transcription('e12d05fe-6979-485c-83dc-9276114dba3b')

self.assertResponseMatches(transcription)

Expand All @@ -27,7 +27,7 @@ def test_get(self):

@with_response(201)
def test_create(self):
self.client.transcriptions.create_tanscription(
self.client.transcriptions.create_transcription(
recording_id='8605287e-1e1a-4341-8235-23574357d6f1')

# self.assertResponseMatches(transcription)
Expand All @@ -46,7 +46,7 @@ def test_create(self):

@with_response(202)
def test_delete(self):
transcription = self.client.transcriptions.delete_tanscription(
transcription = self.client.transcriptions.delete_transcription(
'8605287e-1e1a-4341-8235-23574357d6f1')

self.assertResponseMatches(transcription)
Expand Down

0 comments on commit 70f8e20

Please sign in to comment.